Browse Source

fix: query empty not allow (#255)

tags/0.3.2
John Wang 2 years ago
parent
commit
ccd80653ff
No account linked to committer's email address
1 changed files with 4 additions and 0 deletions
  1. 4
    0
      api/services/completion_service.py

+ 4
- 0
api/services/completion_service.py View File

# is streaming mode # is streaming mode
inputs = args['inputs'] inputs = args['inputs']
query = args['query'] query = args['query']

if not query:
raise ValueError('query is required')

conversation_id = args['conversation_id'] if 'conversation_id' in args else None conversation_id = args['conversation_id'] if 'conversation_id' in args else None


conversation = None conversation = None

Loading…
Cancel
Save