mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-10-04 04:04:14 +00:00
chore: unpublish /inference/chat-completion (#3609)
# What does this PR do?
BREAKING CHANGE: removes /inference/chat-completion route and updates
relevant documentation
## Test Plan
🤷
This commit is contained in:
parent
62e302613f
commit
cb33f45c11
23 changed files with 1448 additions and 2137 deletions
|
@ -102,15 +102,15 @@
|
|||
" }\n",
|
||||
"\n",
|
||||
" cprint(\"User> Sending image for analysis...\", \"green\")\n",
|
||||
" response = client.inference.chat_completion(\n",
|
||||
" response = client.chat.completions.create(\n",
|
||||
" messages=[message],\n",
|
||||
" model_id=MODEL_NAME,\n",
|
||||
" model=MODEL_NAME,\n",
|
||||
" stream=stream,\n",
|
||||
" )\n",
|
||||
"\n",
|
||||
" cprint(f'Assistant> ', color='cyan', end='')\n",
|
||||
" if not stream:\n",
|
||||
" cprint(response.completion_message.content, color='yellow')\n",
|
||||
" cprint(response.choices[0].message.content, color='yellow')\n",
|
||||
" else:\n",
|
||||
" for chunk in response:\n",
|
||||
" cprint(chunk.event.delta.text, color='yellow', end='')\n",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue