Skip to content

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
dargilco committed Jul 31, 2024
1 parent a6bc388 commit 7052b47
Show file tree
Hide file tree
Showing 19 changed files with 127 additions and 118 deletions.
2 changes: 2 additions & 0 deletions specification/ai/ModelClient/client.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ namespace Customizations; // The actual name here doesn't matter and is here for
@@access(AI.Model.ChatCompletionsNamedToolSelection, Access.public);
@@access(AI.Model.ChatCompletionsFunctionToolSelection, Access.public);
@@access(AI.Model.ChatCompletionsResponseFormat, Access.public);
@@access(AI.Model.ChatCompletionsResponseFormatJSON, Access.public);
@@access(AI.Model.ChatCompletionsResponseFormatText, Access.public);
@@access(AI.Model.ChatCompletionsToolCall, Access.public);
@@access(AI.Model.ChatCompletionsToolDefinition, Access.public);
@@access(AI.Model.ChatCompletionsToolSelectionPreset, Access.public);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,57 +10,57 @@
"role": "ChatRequestMessage"
}
],
"frequency_penalty": 0,
"frequency_penalty": 1,
"stream": true,
"presence_penalty": 0,
"presence_penalty": -1,
"temperature": 0,
"top_p": 0,
"max_tokens": 0,
"response_format": {
"type": "ChatCompletionsResponseFormat"
},
"stop": [
"kodvfgvdeveyjajzhgiywjolk"
"mzmcfubofv"
],
"tools": [
{
"type": "function",
"function": {
"name": "dvvmxwwwizffnvmelspghalpgitf",
"description": "evocwt",
"name": "ju",
"description": "ysuwjrgnnbotcurdvzoade",
"parameters": {}
}
}
],
"seed": 25,
"model": "iezn"
"seed": 5,
"model": "c"
}
},
"responses": {
"200": {
"body": {
"id": "vtgwqaohn",
"created": 15,
"model": "qoqzxiwwpxoputj",
"id": "ranyivlrubzwazjibryqvjrg",
"created": 25,
"model": "nfldvjnmoxfwkqzuqkxbzbred",
"usage": {
"completion_tokens": 20,
"prompt_tokens": 14,
"total_tokens": 19
"completion_tokens": 18,
"prompt_tokens": 28,
"total_tokens": 5
},
"choices": [
{
"index": 12,
"index": 28,
"finish_reason": "stop",
"message": {
"role": "system",
"content": "lyknnetfzfwkzohcnpm",
"content": "gjahropbocvhmlvoyitwihd",
"tool_calls": [
{
"id": "guoqqduggmjcfnwkuwfbchljtyat",
"id": "ytt",
"type": "function",
"function": {
"name": "dvvmxwwwizffnvmelspghalpgitf",
"arguments": "cznrrqnbgf"
"name": "ju",
"arguments": "pbayscgxeazdbhvtmjqpzueyga"
}
}
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,21 @@
"responses": {
"200": {
"body": {
"id": "vtgwqaohn",
"created": 15,
"model": "qoqzxiwwpxoputj",
"id": "ranyivlrubzwazjibryqvjrg",
"created": 25,
"model": "nfldvjnmoxfwkqzuqkxbzbred",
"usage": {
"completion_tokens": 20,
"prompt_tokens": 14,
"total_tokens": 19
"completion_tokens": 18,
"prompt_tokens": 28,
"total_tokens": 5
},
"choices": [
{
"index": 12,
"index": 28,
"finish_reason": "stop",
"message": {
"role": "system",
"content": "lyknnetfzfwkzohcnpm"
"content": "gjahropbocvhmlvoyitwihd"
}
}
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,31 @@
"extra-parameters": "error",
"body": {
"input": [
"jizdyle"
"nxehxxnjznyixf"
],
"dimensions": 22,
"dimensions": 3,
"encoding_format": "base64",
"input_type": "text",
"model": "nddvsjz"
"model": "zflys"
}
},
"responses": {
"200": {
"body": {
"id": "vionieqnhlphxavcx",
"id": "kmclubpbyrjjrcihu",
"data": [
{
"embedding": [
6
3
],
"index": 14
"index": 20
}
],
"usage": {
"prompt_tokens": 20,
"prompt_tokens": 17,
"total_tokens": 25
},
"model": "ieciyihyttwmfe"
"model": "gg"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,27 @@
"api-version": "2024-05-01-preview",
"body": {
"input": [
"scgp"
"ujbdzqgintkjjorqvgtyqxehwod"
]
}
},
"responses": {
"200": {
"body": {
"id": "vionieqnhlphxavcx",
"id": "kmclubpbyrjjrcihu",
"data": [
{
"embedding": [
6
3
],
"index": 14
"index": 20
}
],
"usage": {
"prompt_tokens": 20,
"prompt_tokens": 17,
"total_tokens": 25
},
"model": "ieciyihyttwmfe"
"model": "gg"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,33 +7,33 @@
"body": {
"input": [
{
"image": "ezdcmifjtdbrcbgnqytppc",
"text": "ryxmjwpedcy"
"image": "gvmojtfooxixxzayrditjlyymg",
"text": "iujicnoralolceytmoeabhftpevhh"
}
],
"dimensions": 17,
"dimensions": 30,
"encoding_format": "base64",
"input_type": "text",
"model": "cwpakajnobxvxijobxq"
"model": "uptjbssrfitjnhlfqddnsabu"
}
},
"responses": {
"200": {
"body": {
"id": "vionieqnhlphxavcx",
"id": "kmclubpbyrjjrcihu",
"data": [
{
"embedding": [
6
3
],
"index": 14
"index": 20
}
],
"usage": {
"prompt_tokens": 20,
"prompt_tokens": 17,
"total_tokens": 25
},
"model": "ieciyihyttwmfe"
"model": "gg"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,28 @@
"body": {
"input": [
{
"image": "ezdcmifjtdbrcbgnqytppc"
"image": "gvmojtfooxixxzayrditjlyymg"
}
]
}
},
"responses": {
"200": {
"body": {
"id": "vionieqnhlphxavcx",
"id": "kmclubpbyrjjrcihu",
"data": [
{
"embedding": [
6
3
],
"index": 14
"index": 20
}
],
"usage": {
"prompt_tokens": 20,
"prompt_tokens": 17,
"total_tokens": 25
},
"model": "ieciyihyttwmfe"
"model": "gg"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
"responses": {
"200": {
"body": {
"model_name": "ojuagnemgirsmgxmqbkppwiu",
"model_name": "ay",
"model_type": "embeddings",
"model_provider_name": "c"
"model_provider_name": "wgjopneqzhgrzsgskwcojdpwlmu"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
"responses": {
"200": {
"body": {
"model_name": "ojuagnemgirsmgxmqbkppwiu",
"model_name": "ay",
"model_type": "embeddings",
"model_provider_name": "c"
"model_provider_name": "wgjopneqzhgrzsgskwcojdpwlmu"
}
}
}
Expand Down
3 changes: 3 additions & 0 deletions specification/ai/ModelClient/models/chat_completions.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -357,6 +357,9 @@ model ChatRequestToolMessage extends ChatRequestMessage {

@doc("A representation of a chat message update as received in a streaming response.")
model StreamingChatResponseMessageUpdate {
@doc("The chat role associated with the message. If present, should always be 'assistant'")
role?: ChatRole;

//#suppress "@azure-tools/typespec-azure-core/no-nullable" "explicitly nullable in mirrored API"
@doc("The content of the message.")
content?: string;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,57 +10,57 @@
"role": "ChatRequestMessage"
}
],
"frequency_penalty": 0,
"frequency_penalty": 1,
"stream": true,
"presence_penalty": 0,
"presence_penalty": -1,
"temperature": 0,
"top_p": 0,
"max_tokens": 0,
"response_format": {
"type": "ChatCompletionsResponseFormat"
},
"stop": [
"kodvfgvdeveyjajzhgiywjolk"
"mzmcfubofv"
],
"tools": [
{
"type": "function",
"function": {
"name": "dvvmxwwwizffnvmelspghalpgitf",
"description": "evocwt",
"name": "ju",
"description": "ysuwjrgnnbotcurdvzoade",
"parameters": {}
}
}
],
"seed": 25,
"model": "iezn"
"seed": 5,
"model": "c"
}
},
"responses": {
"200": {
"body": {
"id": "vtgwqaohn",
"created": 15,
"model": "qoqzxiwwpxoputj",
"id": "ranyivlrubzwazjibryqvjrg",
"created": 25,
"model": "nfldvjnmoxfwkqzuqkxbzbred",
"usage": {
"completion_tokens": 20,
"prompt_tokens": 14,
"total_tokens": 19
"completion_tokens": 18,
"prompt_tokens": 28,
"total_tokens": 5
},
"choices": [
{
"index": 12,
"index": 28,
"finish_reason": "stop",
"message": {
"role": "system",
"content": "lyknnetfzfwkzohcnpm",
"content": "gjahropbocvhmlvoyitwihd",
"tool_calls": [
{
"id": "guoqqduggmjcfnwkuwfbchljtyat",
"id": "ytt",
"type": "function",
"function": {
"name": "dvvmxwwwizffnvmelspghalpgitf",
"arguments": "cznrrqnbgf"
"name": "ju",
"arguments": "pbayscgxeazdbhvtmjqpzueyga"
}
}
]
Expand Down
Loading

0 comments on commit 7052b47

Please sign in to comment.