Closed KylinMountain closed 2 months ago
seccond bug: when doing query, some config is not load from setting.yaml.
llm:
api_key: sk-xxxxx
type: openai_chat # or azure_openai_chat
model: moonshot-v1-32k
model_supports_json: false # recommended if this is available for your model.
api_base: https://api.moonshot.cn/v1
max_tokens: 32768
concurrent_requests: 1 # the number of parallel inflight requests that may be made
tokens_per_minute: 32000 # set a leaky bucket throttle
requests_per_minute: 3 # set a leaky bucket throttle
# request_timeout: 180.0
# api_version: 2024-02-15-preview
# organization: <organization_id>
# deployment_name: <azure_model_deployment_name>
max_retries: 3
max_retry_wait: 10
sleep_on_rate_limit_recommendation: true # whether to sleep when azure suggests wait-times
I have set tokens_per_minute to 32000, but it loads with 'tokens_per_minute': 0, 'requests_per_minute': 0.
INFO: Reading settings from settings.yaml
creating llm client with {'api_key': 'REDACTED,len=51', 'type': "openai_chat", 'model': 'moonshot-v1-32k', 'max_tokens': 32768, 'request_timeout': 180.0, 'api_base': 'https://api.moonshot.cn/v1', 'api_version': None, 'organization': None, 'proxy': None, 'cognitive_services_endpoint': None, 'deployment_name': None, 'model_supports_json': False, 'tokens_per_minute': 0, 'requests_per_minute': 0, 'max_retries': 3, 'max_retry_wait': 10.0, 'sleep_on_rate_limit_recommendation': True, 'concurrent_requests': 1}
Update the tokens_per_minute to tpm and requests_per_minute to rpm will work.
Hi @KylinMountain Thanks for reporting and updating!
I'll be taking a look at the community_report:llm issue you reported. Regarding #382 I updated your PR with the resolution from another PR
Thanks for contributing, we appreciate this.
Update the tokens_per_minute to tpm and requests_per_minute to rpm will work.
The field name defined in GraphRagConfig
is community_reports
, while the settings.yaml created by the project initialization code (init_content.py
) has community_report
. This mismatch prevents the corresponding configuration from being read. Change 'community_report:' to 'community_reports:' in your settings.yaml and it will work.
when you override llm in
it always use the llm in setting.yaml when
create_final_community_reports