specs-ai-remote-service

Integrate Gemini, OpenAI, and Snap3D APIs into Specs lenses via the Remote Service Gateway package.

16|2|Updated Apr 13, 2026
One-click install
npx skills add https://github.com/lens-studio-devs/ls-extensions --skill specs-ai-remote-service-lens-studio-devs
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: specs-ai-remote-service
Source: https://github.com/lens-studio-devs/ls-extensions/tree/main/plugins/ls-clad/skills/specs-ai-remote-service
Command: npx skills add https://github.com/lens-studio-devs/ls-extensions --skill specs-ai-remote-service-lens-studio-devs

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve? Building AI features (chat, voice, vision, image generation, function calling) in Lens Studio for Specs requires correctly installing the Remote Service Gateway package, generating provider tokens, wiring scene hierarchies, and avoiding undocumented pitfalls like wrong Gemini model IDs and broken ASR event names. This Skill encodes all of that operational knowledge so the agent sets up working AI integrations without trial and error. ## Core Features & Use Cases - Zero-friction authentication: Programmatically generates all three provider tokens (SNAP, OPENAI, GOOGLE) via ExecuteEditorCode and wires them to the RemoteServiceGatewayCredentials component, with a UI fallback path. - Canonical assistant scripts: Provides copy-ready AIAssistant, GeminiAssistant, and OpenAIAssistant TypeScript implementations covering chat completions, Gemini Live, OpenAI Realtime, ASR hold-to-talk, and function calling. - Scene hierarchy automation: Supplies an idempotent ExecuteEditorCode bootstrap that builds the Requirements infrastructure (credentials, MicrophoneRecorder, DynamicAudioOutput) and wiring maps for all @input fields. - Use Case: A user asks for a voice-controlled AI assistant on Specs. The agent installs RSG 0.2.0+, generates tokens, copies the canonical scripts, builds the scene hierarchy, and verifies the ScriptComponents exist — producing a working hold-to-talk assistant with no manual wiring. ## Quick Start Set up a voice AI assistant in my Lens Studio project using the Remote Service Gateway with Gemini Live and hold-to-talk ASR.

Frequently Asked Questions about specs-ai-remote-service

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I integrate the Gemini Live API into a Lens Studio project?

Install the RemoteServiceGateway package version 0.2.0 or higher, copy the GeminiAssistant script into Assets, and create a SceneObject with an attached ScriptComponent via ExecuteEditorCode. Use the model ID models/gemini-2.0-flash-live-preview-04-09 and wait for setupComplete before attaching microphone listeners.

How do I generate Remote Service Gateway tokens in Lens Studio?

In Lens Studio 22+, the agent generates all three tokens (SNAP, OPENAI, GOOGLE) programmatically via ExecuteEditorCode calling Network.performAuthorizedHttpRequest against the smart-gate token endpoint. If that path fails, use Window > Remote Service Gateway Token > Generate, then save the scene with Cmd+S.

Why does Gemini image generation return a 404 through the Remote Service Gateway?

Gemini image model IDs like gemini-2.0-flash-exp and gemini-2.5-flash-image-preview are not available through RSG's Vertex backend and return Publisher Model not found errors. Use the Imagen endpoint instead: Gemini.generateImage with model imagen-3.0-generate-002.

Does ASR transcription work in Lens Studio Preview?

No, the AsrModule runs on-device only and Preview always returns Nothing heard. ASR requires Lens Studio v5.9.0+, Snap OS v5.61+, and a physical Specs device, with transcription started from OnStartEvent rather than onAwake.

Why is my SUIK button hold-to-talk not triggering ASR?

SUIK Button hold events are onTriggerDown and onTriggerUp; onTriggerStart and onTriggerEnd do not exist and silently no-op with no compile error. Wire startTranscribing to onTriggerDown and stopTranscribing to onTriggerUp.

What Remote Service Gateway version is required for token generation?

Version 0.2.0 or higher is required. Older versions lack the RemoteServiceGatewayToken plugin and use a different credentials schema, causing silent token wiring failures. Check the package.json version or look for the RemoteServiceGatewayToken folder under Plugins.