KAG icon indicating copy to clipboard operation
KAG copied to clipboard

[Bug] [kag] invalid vectorizer config: 'No configuration setting found for key path'

Open xutengfei763 opened this issue 11 months ago • 5 comments

Search before asking

  • [X] I had searched in the issues and found no similar issues.

Operating system information

Linux

What happened

when i save the global configuration ,the errors occur, how can i fex it image

image

How to reproduce

download https://raw.githubusercontent.com/OpenSPG/openspg/refs/heads/master/dev/release/docker-compose-west.yml run docker-compose -f docker-compose.yml up -d login and go to this page, full the form and submit, the error will occur

Are you willing to submit PR?

  • [ ] Yes I am willing to submit a PR!

xutengfei763 avatar Jan 10 '25 03:01 xutengfei763

Search before asking

  • [x] I had searched in the issues and found no similar issues.

Operating system information

Linux

What happened

when i save the global configuration ,the errors occur, how can i fex it image

image

How to reproduce

download https://raw.githubusercontent.com/OpenSPG/openspg/refs/heads/master/dev/release/docker-compose-west.yml run docker-compose -f docker-compose.yml up -d login and go to this page, full the form and submit, the error will occur

Are you willing to submit PR?

  • [ ] Yes I am willing to submit a PR!

It looks like your vectorizer configuration is NULL, and should be filled with representation model service conf.

caszkgui avatar Jan 10 '25 08:01 caszkgui

Search before asking

  • [x] I had searched in the issues and found no similar issues.

Operating system information

Linux

What happened

when i save the global configuration ,the errors occur, how can i fex it image image

How to reproduce

download https://raw.githubusercontent.com/OpenSPG/openspg/refs/heads/master/dev/release/docker-compose-west.yml run docker-compose -f docker-compose.yml up -d login and go to this page, full the form and submit, the error will occur

Are you willing to submit PR?

  • [ ] Yes I am willing to submit a PR!

It looks like your vectorizer configuration is NULL, and should be filled with representation model service conf.

image my configuration, i use the maas,not local embedding model. i tried use command knext to create knowadge, it works.
but use the web page, it not works, it has the errors.

xutengfei763 avatar Jan 10 '25 08:01 xutengfei763

Same here, i tried using OLLAMA but it doesn't work.

ashunaveed avatar Jan 10 '25 15:01 ashunaveed

Search before asking

  • [x] I had searched in the issues and found no similar issues.

Operating system information

Linux

What happened

when i save the global configuration ,the errors occur, how can i fex it image image

How to reproduce

download https://raw.githubusercontent.com/OpenSPG/openspg/refs/heads/master/dev/release/docker-compose-west.yml run docker-compose -f docker-compose.yml up -d login and go to this page, full the form and submit, the error will occur

Are you willing to submit PR?

  • [ ] Yes I am willing to submit a PR!

It looks like your vectorizer configuration is NULL, and should be filled with representation model service conf.

image my configuration, i use the maas,not local embedding model. i tried use command knext to create knowadge, it works. but use the web page, it not works, it has the errors.

api_key filed of vector configuration should be filled with real api_key value, which can be acquired from commercial model service provider such as openai or siliconflow.

image

caszkgui avatar Jan 11 '25 03:01 caszkgui

Same here, i tried using OLLAMA but it doesn't work.

It looks like your local model loaded by OLLAMA is not accessible by openspg-server container. You can refer to User Guide for Model Service Configuration to test accessibility.

image

caszkgui avatar Jan 11 '25 03:01 caszkgui

maybe it is not this reason,I filled the real api_key .There are two situations the first is: common configuration,and the errors: image image the second is : model configuration,and the errors: image image

And I searched the database,the value is empty: select * from kg_config where config_id = 'KAG_CONFIG' image

And I decompiled the source code , because of the json key graph_store is not exists ,so the errors occur. image

follow the same idea, I decompiled the source code for the first error, the error occured wher check the json key "vectorizer". and the python executed errors. image image image image

xutengfei763 avatar Jan 14 '25 01:01 xutengfei763

maybe it is not this reason,I filled the real api_key .There are two situations the first is: common configuration,and the errors: image image the second is : model configuration,and the errors: image image

And I searched the database,the value is empty: select * from kg_config where config_id = 'KAG_CONFIG' image

And I decompiled the source code , because of the json key graph_store is not exists ,so the errors occur. image

follow the same idea, I decompiled the source code for the first error, the error occured wher check the json key "vectorizer". and the python executed errors. image image image image

It looks like you have not settled common configuration yet,in which graph store should be filled. You can refer to User Guide for Startup to get detail information of Create a knowledge base.

https://github.com/OpenSPG/openspg/pull/105/files#diff-831cd845e2cd8e24b72cce0c80930f14a6bda5310cc7b579791b35fff5051fbf

caszkgui avatar Jan 14 '25 01:01 caszkgui

I tried update the database using :update kg_config set config = '{"graph_store":{"database":"neo4j","password":"neo4j@openspg","uri":"neo4j://release-openspg-neo4j:7687","user":"neo4j"},"vectorizer":{"type":"bge_m3","model":"BAAI/bge-m3","base_url":"https://api.siliconflow.cn/v1","api_key":"sk-gqdmllzbuybpqblewpxxxxxxxxjdkfxqcvgfyrg"},"prompt":{"biz_scene":"default","language":"zh"},"llm":{"type":"maas","creator":"openspg","createTime":"2025-01-10 09:31:49","model":"glm-4-flash","base_url":"https://open.bigmodel.cn/api/paas/v4","desc":"glm","api_key":"8253c27fxxxxxx5a798ffc809bcc0b.xxxxxx","temperature":0.7,"stream":"False","default":true}}' where config_id = 'KAG_CONFIG' and version = '1';

after that ,the web can show the configuration, but it cannnot changed ,it will occur the same error. Every time it will check "vectorizer"

1: change the common configuration: image 2:add new model configuration: image 3:create the knowledge: image

xutengfei763 avatar Jan 14 '25 01:01 xutengfei763

image type: bge_m3 is incorrect, it should be type: openai.

xionghuaidong avatar Jan 14 '25 11:01 xionghuaidong

image type: bge_m3 is incorrect, it should be type: openai.

thanks ,it works

xutengfei763 avatar Jan 15 '25 01:01 xutengfei763