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

[Question]: 运行的Solon项目,项目跑起来之后,运行/chat接口报错 #39

Closed
2 tasks done
Time-Boat opened this issue Feb 22, 2025 · 1 comment
Closed
2 tasks done
Labels
question Further information is requested

Comments

@Time-Boat
Copy link

您的问题

项目下载之后,修改app.yml中的solon.env环境为deepseek,并添加了apikey,其他的代码没有变化

版本信息

1.4.3

补充信息

io.github.pigmesh.ai.deepseek.core.OpenAiHttpException: Failed to deserialize the JSON body into the target type: missing field `model` at line 7 column 1
	at io.github.pigmesh.ai.deepseek.core.Utils.toException(Utils.java:15)
	at io.github.pigmesh.ai.deepseek.core.SyncRequestExecutor.execute(SyncRequestExecutor.java:29)
	at io.github.pigmesh.ai.deepseek.core.RequestExecutor.execute(RequestExecutor.java:59)
	at io.github.pigmesh.ai.deepseek.solon.example.controller.DeepSeekLocalController.chat(DeepSeekLocalController.java:24)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at org.noear.solon.core.wrap.MethodWrap.invoke(MethodWrap.java:269)
	at org.noear.solon.core.wrap.MethodWrap.doIntercept(MethodWrap.java:258)
	at org.noear.solon.core.aspect.InterceptorEntity.doIntercept(InterceptorEntity.java:55)
	at org.noear.solon.core.aspect.Invocation.invoke(Invocation.java:115)
	at org.noear.solon.core.wrap.MethodWrap.invokeByAspect(MethodWrap.java:284)
	at org.noear.solon.core.mvc.ActionDefault.executeDo(ActionDefault.java:396)
	at org.noear.solon.core.mvc.ActionDefault.invokeMethodDo(ActionDefault.java:327)
	at org.noear.solon.core.mvc.ActionDefault.invokeHandleDo(ActionDefault.java:304)
	at org.noear.solon.core.handle.FilterChainImpl.doFilter(FilterChainImpl.java:51)
	at org.noear.solon.core.mvc.ActionDefault.invokeFilterDo(ActionDefault.java:296)
	at org.noear.solon.core.handle.FilterChainImpl.doFilter(FilterChainImpl.java:51)
	at org.noear.solon.core.mvc.ActionDefault.invoke(ActionDefault.java:270)
	at org.noear.solon.core.mvc.ActionDefault.handle(ActionDefault.java:247)
	at org.noear.solon.core.route.RouterHandler.handleMain(RouterHandler.java:51)
	at org.noear.solon.core.route.RouterHandler.handle1(RouterHandler.java:71)
	at org.noear.solon.core.route.RouterInterceptorChainImpl.doIntercept(RouterInterceptorChainImpl.java:54)
	at org.noear.solon.core.ChainManager.doIntercept(ChainManager.java:199)
	at org.noear.solon.core.route.RouterHandler.handle(RouterHandler.java:102)
	at org.noear.solon.core.handle.HandlerPipeline.handle(HandlerPipeline.java:53)
	at org.noear.solon.core.handle.FilterChainImpl.doFilter(FilterChainImpl.java:51)
	at org.noear.solon.web.cors.CrossFilter.doFilter(CrossFilter.java:47)
	at org.noear.solon.core.handle.FilterChainImpl.doFilter(FilterChainImpl.java:49)
	at org.noear.solon.logging.integration.XPluginImp.lambda$start$1(XPluginImp.java:71)
	at org.noear.solon.core.handle.FilterChainImpl.doFilter(FilterChainImpl.java:49)
	at org.noear.solon.core.ChainManager.doFilter(ChainManager.java:106)
	at org.noear.solon.SolonApp.tryHandle(SolonApp.java:511)
	at org.noear.solon.boot.smarthttp.http.SmHttpContextHandler.handleDo(SmHttpContextHandler.java:122)
	at org.noear.solon.boot.smarthttp.http.SmHttpContextHandler.handle0(SmHttpContextHandler.java:100)
	at org.noear.solon.boot.smarthttp.http.SmHttpContextHandler.lambda$handle$0(SmHttpContextHandler.java:85)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.base/java.lang.Thread.run(Thread.java:840)

提问前确认

  • 我已经搜索过现有的 issues,但没有找到答案
  • 我已经阅读过文档
@Time-Boat Time-Boat added the question Further information is requested label Feb 22, 2025
@pig-mesh pig-mesh deleted a comment from wxnewtouch Feb 22, 2025
@lltx
Copy link
Contributor

lltx commented Feb 22, 2025

https://javaai.pig4cloud.com/deepseek/quickstart

看下文档配置一下model

@lltx lltx closed this as completed Feb 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants