Thin client + CLI for Azure AI Foundry agent NatureLM-Idun-5-MoE
Project description
Idun SDK
Thin, stdlib-only client + CLI for the NatureLM-Idun-5-MoE agent on Azure AI Foundry.
No httpx, no azure-identity, no Flask — it runs headless on Termux/Android with
nothing but the Python standard library. Idun is a tool agent (it reasons and
calls tools like web_search); this SDK surfaces the full agent trajectory
(reasoning steps + tool calls) instead of a black-box answer.
Install
pip install idun-sdk
Installs the idun CLI, the idun Python package, and the stdlib MCP server
idun_mcp.py.
Authenticate
idun login # device-code flow, token saved to ~/foundry_token.txt
No admin role required — idun login returns a plain Entra bearer token for
the Foundry endpoint. Any tenant user with agent access (RBAC) can run it; admin
rights are only needed to configure the agent, not to use it. The token
auto-rotates before expiry.
Quickstart
# final answer only
idun chat "Summarize Contoso's sustainability communications in one sentence."
# full agent trajectory (reasoning + tool steps)
idun trace "Use web_search to find the current CEO of Contoso."
from idun import IdunClient
res = IdunClient().complete("Your prompt here")
print(res.text) # final answer
for s in res.steps: # agent trajectory
print(s.kind, s.tool, s.query, s.status)
Features
| Command | Purpose |
|---|---|
idun chat |
final answer only |
idun trace |
full trajectory (steps + text) |
idun export |
trajectory as JSON / Markdown |
idun packs / idun run |
curated prompt packs (e.g. Contoso) |
idun diff |
side-by-side trace diff of two prompts |
idun token |
inspect / refresh the Foundry token |
idun logo |
print the Foundry logo |
MCP server
idun_mcp.py is a zero-dependency stdio MCP server (no FastMCP / httpx):
python3 idun_mcp.py
Exposes idun_chat(prompt) and idun_trace(prompt). Add to any MCP client:
{ "mcpServers": { "idun": { "command": "python3", "args": ["/abs/path/idun-sdk/idun_mcp.py"] } } }
Docs mirror (GitMCP): https://gitmcp.io/qapdex-maker/idun-sdk/sse
Request shape (verified)
POST {base}/api/projects/{project}/agents/{agent}/endpoint/protocols/openai/responses?api-version=2025-05-15-preview
Authorization: Bearer ***
{"model": "model-router", "input": "<prompt>", "max_output_tokens": 4096}
modelMUST be"model-router"(agent id is in the URL).- Do not send a
toolskey — the agent owns its tools (else400 invalid_payload).
Links
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file idun_sdk-0.1.13.tar.gz.
File metadata
- Download URL: idun_sdk-0.1.13.tar.gz
- Upload date:
- Size: 31.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
32ba868697e88015ac17ce89d1092de0dac6832fa052e0f838648f6d4f982ec0
|
|
| MD5 |
30486f2192985780c10b1c23d07a3471
|
|
| BLAKE2b-256 |
206ce4a4ca0d12e7b8ec1d95bafd6652e1a3583b1ae39d6dd0692851d4790ca1
|
File details
Details for the file idun_sdk-0.1.13-py3-none-any.whl.
File metadata
- Download URL: idun_sdk-0.1.13-py3-none-any.whl
- Upload date:
- Size: 28.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
56a16978bc1c8134cd4470431ea439e01ea940820e3d1c14cabacd1940ca9152
|
|
| MD5 |
a7e466843dc22a459ea833a6d178af4e
|
|
| BLAKE2b-256 |
10c35ae34d2d693951216c21147d13eada0878d6a5a2274a85021fd5ea45f932
|