@tangle-network/agent-app 0.2.0 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,35 +0,0 @@
1
- /**
2
- * Resolve the model config a Tangle agent's sandbox/runtime runs on.
3
- *
4
- * Every Tangle agent product resolves the SAME thing from env: the Tangle Router
5
- * (OpenAI-compatible, metered at the platform markup against a single
6
- * `TANGLE_API_KEY`) by default, with a direct-Anthropic BYOK escape hatch. The
7
- * shape feeds the sandbox SDK's `backend.model`. Lifted here so no product
8
- * hand-rolls the env parsing + the router default.
9
- */
10
- interface TangleModelConfig {
11
- /** The Tangle Router is OpenAI-compatible → driven via `openai-compat`.
12
- * `anthropic` is the BYOK escape hatch. */
13
- provider: 'openai-compat' | 'anthropic';
14
- model: string;
15
- apiKey: string;
16
- baseUrl: string;
17
- }
18
- interface ResolveModelOptions {
19
- /** Env to read (defaults to process.env). */
20
- env?: Record<string, string | undefined>;
21
- /** Router base URL default when `TANGLE_ROUTER_BASE_URL` is unset. */
22
- defaultRouterBaseUrl?: string;
23
- }
24
- declare const DEFAULT_TANGLE_ROUTER_BASE_URL = "https://router.tangle.tools/v1";
25
- /**
26
- * Resolve the model config from env. DEFAULT path (`MODEL_PROVIDER` unset or
27
- * `openai-compat`/`tangle-router`/`tcloud`): the Tangle Router, authenticated
28
- * with `TANGLE_API_KEY`, model from `MODEL_NAME`. BYOK path
29
- * (`MODEL_PROVIDER=anthropic`): direct Anthropic with `ANTHROPIC_API_KEY` +
30
- * `ANTHROPIC_BASE_URL`. Throws (fail-loud) on a missing required var so a
31
- * misconfigured deploy fails at boot, not mid-turn.
32
- */
33
- declare function resolveTangleModelConfig(opts?: ResolveModelOptions): TangleModelConfig;
34
-
35
- export { DEFAULT_TANGLE_ROUTER_BASE_URL as D, type ResolveModelOptions as R, type TangleModelConfig as T, resolveTangleModelConfig as r };