Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR: Exception in ASGI application #1290

Open
Infinirc opened this issue Jun 18, 2024 · 1 comment
Open

ERROR: Exception in ASGI application #1290

Infinirc opened this issue Jun 18, 2024 · 1 comment
Labels
support A request for help setting things up

Comments

@Infinirc
Copy link

Hello everyone, I have the following problem when using Huggingface ChatUI with FastChat. How can I change the configuration? Use npm to start development mode.
Thanks

MODELS=`[
  {
    "name": "Infinirc-7b-Llama2",
    "id": "Infinirc-7b-Llama2",
    "model": "Infinirc-7b-Llama2",
    "parameters": {
      "temperature": 0.9,
      "top_p": 0.95,
      "repetition_penalty": 1.2,
      "top_k": 50,
      "truncate": 1000,
      "max_new_tokens": 1024,
      "stop": []
    },
    "endpoints": [{
      "type" : "openai",
      "baseURL": "http://69.30.85.183:22152/v1",
      
      "accessToken": "x"

    }]
  }
]`

FastChat:

`2024-06-18 01:07:42 | INFO | stdout | INFO:     59.125.15.126:60166 - "POST /v1/chat/completions HTTP/1.1" 500 Internal Server Error
2024-06-18 01:07:42 | ERROR | stderr | ERROR:    Exception in ASGI application
2024-06-18 01:07:42 | ERROR | stderr | Traceback (most recent call last):
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/httptools_impl.py", line 399, in run_asgi
2024-06-18 01:07:42 | ERROR | stderr |     result = await app(  # type: ignore[func-returns-value]
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 70, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     return await self.app(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 1054, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     await super().__call__(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 123, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     await self.middleware_stack(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 186, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     raise exc
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 164, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     await self.app(scope, receive, _send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 85, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     await self.app(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 65, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app
2024-06-18 01:07:42 | ERROR | stderr |     raise exc
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app
2024-06-18 01:07:42 | ERROR | stderr |     await app(scope, receive, sender)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 756, in __call__
2024-06-18 01:07:42 | ERROR | stderr |     await self.middleware_stack(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 776, in app
2024-06-18 01:07:42 | ERROR | stderr |     await route.handle(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 297, in handle
2024-06-18 01:07:42 | ERROR | stderr |     await self.app(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 77, in app
2024-06-18 01:07:42 | ERROR | stderr |     await wrap_app_handling_exceptions(app, request)(scope, receive, send)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 64, in wrapped_app
2024-06-18 01:07:42 | ERROR | stderr |     raise exc
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 53, in wrapped_app
2024-06-18 01:07:42 | ERROR | stderr |     await app(scope, receive, sender)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 72, in app
2024-06-18 01:07:42 | ERROR | stderr |     response = await func(request)
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 278, in app
2024-06-18 01:07:42 | ERROR | stderr |     raw_response = await run_endpoint_function(
2024-06-18 01:07:42 | ERROR | stderr |   File "/usr/local/lib/python3.10/dist-packages/fastapi/routing.py", line 191, in run_endpoint_function
2024-06-18 01:07:42 | ERROR | stderr |     return await dependant.call(**values)
2024-06-18 01:07:42 | ERROR | stderr |   File "/workspace/FastChat/fastchat/serve/openai_api_server.py", line 423, in create_chat_completion
2024-06-18 01:07:42 | ERROR | stderr |     gen_params = await get_gen_params(
2024-06-18 01:07:42 | ERROR | stderr |   File "/workspace/FastChat/fastchat/serve/openai_api_server.py", line 332, in get_gen_params
2024-06-18 01:07:42 | ERROR | stderr |     prompt = conv.get_prompt()
2024-06-18 01:07:42 | ERROR | stderr |   File "/workspace/FastChat/fastchat/conversation.py", line 82, in get_prompt
2024-06-18 01:07:42 | ERROR | stderr |     ret += role + ": " + message + self.sep
2024-06-18 01:07:42 | ERROR | stderr | TypeError: can only concatenate str (not "tuple") to str`
@nsarrazin nsarrazin added the support A request for help setting things up label Jun 18, 2024
@useryyi
Copy link

useryyi commented Jun 23, 2024

我也遇到同样的问题

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
support A request for help setting things up
Projects
None yet
Development

No branches or pull requests

3 participants