Talk to your inference.sh agent from Even Realities G2 glasses through Even AI.
How it works
Even AI can hand your questions to a custom agent. It transcribes your speech on its side, sends the text to a URL you give it, and shows the reply on the glasses. inference.sh serves that URL for every agent, so there is nothing to host or deploy.
Your agent keeps its own system prompt, tools, skills and memory. Conversations from the glasses show up in the agent's chat list like any other chat.
What you need
- An agent. Any agent you can run works. To make one, see Creating an agent.
- An API key with the
agents:executescope. See API keys. - The Even app paired with your G2 glasses.
Connect the glasses
-
In the Even app, open Even AI and choose Add Agent.
-
Set the URL, replacing
<namespace>/<name>with your agent (for exampleacme/assistant):code1https://api.inference.sh/agents/<namespace>/<name>/openai/chat/completions?channel=g2&continue=10m&wait=25s&max_chars=400 -
Set the token to your inference.sh API key.
-
Save, then ask Even AI something. The answer comes from your agent.
What the URL options do
| Option | Effect on the glasses |
|---|---|
channel=g2 | Marks the chats the glasses create, so they never continue one of your web chats. |
continue=10m | A question within 10 minutes of the last one continues the same conversation. After that, a new chat starts. |
wait=25s | Even AI gives up after about 30 seconds. If the agent needs longer, you get the text written so far, or "Still working on it. Ask again in a moment for the answer." The agent keeps working, and your next question lands in the same chat. |
max_chars=400 | Cuts the reply to fit the Even AI card. |
The full reference is in OpenAI-compatible API → Agents.
Tips
- Ask for short answers.
max_charscuts text off; it doesn't make the agent concise. Add something like "Answer in under 60 words, plain text, no markdown" to the agent's system prompt, or make a separate agent for the glasses. - Avoid tools that need approval. The glasses can't show approval or sign-in prompts. If the agent stops for one, the request fails with
input_required. Approve it in the inference.sh app, or turn approval off for tools the glasses use. - Pick up on the web. Open the agent in the inference.sh app to read a glasses conversation in full, with tool calls and anything cut off by
max_chars.