Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ai-client smoke #2878

Draft
wants to merge 9 commits into
base: main
Choose a base branch
from
Draft

ai-client smoke #2878

wants to merge 9 commits into from

Conversation

kazrael2119
Copy link
Contributor

@kazrael2119 kazrael2119 commented Oct 23, 2024

image
$ npx tsp compile ./client.tsp
TypeSpec compiler v0.61.2

Failed to format file: D:\backup\autorest.typescript\packages\typespec-test\test\ai\generated\typespec-ts\src\api\agents\index.ts
Emitter "@azure-tools/typespec-ts" crashed! This is a bug.
Please file an issue at https://github.com/Azure/autorest.typescript/issues

SyntaxError: ':' expected. (16:216)
14 | "instructions": options?.instructions,
15 | "tools": !options?.tools? options?.tools: options?.tools.map((p: any) => { return toolDefinitionUnionSerializer(p)}),

16 | "tool_resources": {"code_interpreter": !options?.toolResources?["codeInterpreter"] ? options?.toolResources?["codeInterpreter"] :codeInterpreterToolResourceSerializer(options?.toolResources?.["codeInterpreter"]),"file_search": !options?.toolResources?["fileSearch"] ? options?.toolResources?["fileSearch"] :fileSearchToolResourceSerializer(options?.toolResources?.["fileSearch"]),"bing_grounding": !options?.toolResources?["bingGrounding"] ? options?.toolResources?["bingGrounding"] :connectionListResourceSerializer(options?.toolResources?.["bingGrounding"]),"microsoft_fabric": !options?.toolResources?["microsoftFabric"] ? options?.toolResources?["microsoftFabric"] :connectionListResourceSerializer(options?.toolResources?.["microsoftFabric"]),"sharepoint": !options?.toolResources?["sharePoint"] ? options?.toolResources?["sharePoint"] :connectionListResourceSerializer(options?.toolResources?.["sharePoint"]),"azure_ai_search": !options?.toolResources?["azureAISearch"] ? options?.toolResources?["azureAISearch"] :azureAISearchResourceSerializer(options?.toolResources?.["azureAISearch"])},
|
^
17 | "temperature": options?.temperature,
18 | "top_p": options?.topP,
19 | "response_format": options?.responseFormat as any,
at Q4 (file:///D:/backup/autorest.typescript/common/temp/node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/plugins/typescript.mjs:17:76108)
at x3 (file:///D:/backup/autorest.typescript/common/temp/node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/plugins/typescript.mjs:20:773)
at Object.w3 [as parse] (file:///D:/backup/autorest.typescript/common/temp/node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/plugins/typescript.mjs:20:1164)
at parse4 (file:///D:/backup/autorest.typescript/common/temp/node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/index.mjs:20685:24)
at coreFormat (file:///D:/backup/autorest.typescript/common/temp/node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/index.mjs:21146:7)
at formatWithCursor (file:///D:/backup/autorest.typescript/common/temp/node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/index.mjs:21348:14)
at format2 (file:///D:/backup/autorest.typescript/common/temp/node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/index.mjs:22733:25)
at emitFile (file:///D:/backup/autorest.typescript/packages/typespec-ts/src/utils/emitUtil.ts:73:29)
at emitContentByBuilder (file:///D:/backup/autorest.typescript/packages/typespec-ts/src/utils/emitUtil.ts:46:7)
at generateModularSources (file:///D:/backup/autorest.typescript/packages/typespec-ts/src/index.ts:331:7)


Library Version 0.33.0
TypeSpec Compiler Version 0.61.2

@kazrael2119 kazrael2119 changed the title ai-client smokw ai-client smoke Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants