open-agents-ai 0.103.38 → 0.103.39

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.
Files changed (2) hide show
  1. package/dist/index.js +6 -2
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -12615,7 +12615,11 @@ async function handleCmd(cmd) {
12615
12615
  }
12616
12616
 
12617
12617
  // Query models from the backend
12618
- const ollamaUrl = args.ollama_url || process.env.OLLAMA_URL || 'http://localhost:11434';
12618
+ var rawUrl = args.ollama_url || process.env.OLLAMA_URL || 'http://localhost:11434';
12619
+ // For passthrough: normalize URL \u2014 strip /v1/chat/completions, /v1, etc. so we can append our own paths
12620
+ const ollamaUrl = isPassthrough
12621
+ ? rawUrl.replace(/\\/+$/, '').replace(/\\/chat\\/completions$/, '').replace(/\\/completions$/, '').replace(/\\/models(\\/.*)?$/, '').replace(/\\/v1$/, '').replace(/\\/+$/, '')
12622
+ : rawUrl;
12619
12623
  let models = [];
12620
12624
 
12621
12625
  if (isPassthrough) {
@@ -46966,7 +46970,7 @@ Respond concisely and safely. Remember: you are talking to the general public.`;
46966
46970
  let targetUrl;
46967
46971
  if (kindOrUrl === "passthrough" || passthrough) {
46968
46972
  kind = "custom";
46969
- targetUrl = config.backendUrl;
46973
+ targetUrl = normalizeBaseUrl(config.backendUrl);
46970
46974
  passthrough = true;
46971
46975
  } else if (knownKinds.includes(kindOrUrl)) {
46972
46976
  kind = kindOrUrl;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "open-agents-ai",
3
- "version": "0.103.38",
3
+ "version": "0.103.39",
4
4
  "description": "AI coding agent powered by open-source models (Ollama/vLLM) — interactive TUI with agentic tool-calling loop",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",