claude-code-router icon indicating copy to clipboard operation
claude-code-router copied to clipboard

Issue with qwen 3 - LM Studio

Open daaddd opened this issue 7 months ago • 1 comments

Image

## enable router
ENABLE_ROUTER=true
export TOOL_AGENT_API_KEY=""
export TOOL_AGENT_BASE_URL="http://127.0.0.1:1234/v1”
export TOOL_AGENT_MODEL="qwen3-14b"

export CODER_AGENT_API_KEY=""
export CODER_AGENT_BASE_URL="http://127.0.0.1:1234/v1”
export CODER_AGENT_MODEL="qwen3-14b"

export THINK_AGENT_API_KEY=""
export THINK_AGENT_BASE_URL="http://127.0.0.1:1234/v1”
export THINK_AGENT_MODEL="qwen3-14b"

export ROUTER_AGENT_API_KEY=""
export ROUTER_AGENT_BASE_URL="http://127.0.0.1:1234/v1"
export ROUTER_AGENT_MODEL="qwen3-14b"

node index.mjs

am I missing anything?

daaddd avatar May 01 '25 04:05 daaddd

Set environment variable to start claude code export DISABLE_PROMPT_CACHING=1 export ANTHROPIC_AUTH_TOKEN="test" export ANTHROPIC_BASE_URL="http://127.0.0.1:3456" export API_TIMEOUT_MS=600000 claude

musistudio avatar May 09 '25 01:05 musistudio

is it work @daaddd ?

DO you the qwen3 30B 2507 thinking or instruct ?

thanks

electroheadfx avatar Jul 31 '25 06:07 electroheadfx

@musistudio it not works for me to use

local llm server[with lmstudio]

(base) ➜  tcp git:(master_mqtt) ✗ curl -X POST http://100.88.175.20:1234/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{
    "model": "glm-4.5-air",
    "messages": [
      {
        "role": "user",
        "content": "Hello, how are you?"
      }
    ]
  }'

{
  "id": "chatcmpl-z89t4rv5sosfojfsqwibwh",
  "object": "chat.completion",
  "created": 1753953072,
  "model": "glm-4.5-air",
  "choices": [
    {
      "index": 0,
      "logprobs": null,
      "finish_reason": "stop",
      "message": {
        "role": "assistant",
        "content": "\n<think>Okay, the user just opened with a simple greeting: \"Hello, how are you?\" This seems like a standard icebreaker to start a conversation. \n\nHmm, I should respond warmly but efficiently since they didn't ask for anything specific yet. The phrasing feels neutral - could be anyone from a casual browser to someone checking if I'm responsive before diving into questions. \n\nI'll keep it upbeat with a cheerful greeting and share my positive state (\"doing great\") to set a friendly tone. Adding an open-ended question encourages them to steer the conversation naturally, though I'll subtly hint that'm ready for more complex interactions too by mentioning \"assist with anything.\" \n\nThe emoji at the end softens it - humans respond well to visual cues in text. No need for overcomplicating here; they'll signal deeper needs next if they have any.</think>Hello! 🌟 I'm doing great, thanks for asking—always ready to help or chat. How about you? What's on your mind today? 😊"
      }
    }
  ],
  "usage": {
    "prompt_tokens": 11,
    "completion_tokens": 208,
    "total_tokens": 219
  },
  "stats": {},
  "system_fingerprint": "glm-4.5-air"
}%

ccr ui is as below:

Image

use command to start cluade

export DISABLE_PROMPT_CACHING=1
export ANTHROPIC_AUTH_TOKEN="test"
export ANTHROPIC_BASE_URL="http://100.88.175.20:1234"
export API_TIMEOUT_MS=600000
claude

but not responsed

Image

ccr code not works either:

Image

mintisan avatar Jul 31 '25 09:07 mintisan

export DISABLE_PROMPT_CACHING=1
export ANTHROPIC_AUTH_TOKEN="test"
export ANTHROPIC_BASE_URL="http://100.88.175.20:1234"
export API_TIMEOUT_MS=600000
claude

This is outdated information, please do not use it. Can you share your claude-code-router.log file?

musistudio avatar Jul 31 '25 12:07 musistudio