Commit Graph
292 Commits
Author SHA1 Message Date
藍+85CD c871df8bc2 chore: release v0.2.0 2025-05-01 12:24:00 +08:00
Makito e1b7ca6e7f feat(generate-image): support url in response_format (#141)
* feat(generate-image): support `url` in `response_format`

* refactor(generate-image): move back `responseBlobAsDataURL`

* style: remove blank line
2025-05-01 12:20:06 +08:00
藍+85CD d0065b1ed2 fix(generate-image)!: fix compatibility with gpt-image-1
closed #139
2025-04-30 21:22:11 +08:00
藍+85CD 6bb9732b59 chore: release v0.2.0-beta.6 2025-04-27 14:10:52 +08:00
藍+85CDandexoticknight e493c0cf69 feat(utils): reasoning (#133)
* feat: reasoning utils

* chore(utils-reasoning): bump version

* feat: add tests for extractReasoning and extractReasoningStream functions

* feat: enhance extractReasoning and extractReasoningStream with new options and add getPartialMatchIndex utility

* feat: update extractReasoning to support separator option and handle multiple reasoning blocks

* docs(utils): add reasoning

* docs(contributing): update

* chore(utils-reasoning): rename file

* chore(utils-reasoning): remove duplicate options

---------

Co-authored-by: exoticknight <draco.knight0@gmail.com>
2025-04-27 13:30:05 +08:00
RainbowBird eb675b3c1a feat(generate-transcription): add language, prompt, temperature to request body (#138) 2025-04-25 20:14:55 +08:00
藍+85CD 7a85c65256 chore: release v0.2.0-beta.5 2025-04-25 16:53:41 +08:00
藍+85CD fcf222d835 chore(shared): simplify 2025-04-25 16:52:24 +08:00
藍+85CD 5c2349b144 refactor(shared): remove cause, included to message
closed #119
2025-04-25 16:49:22 +08:00
藍+85CD b7bb25ce7d chore: fix lint warning 2025-04-25 16:45:04 +08:00
LemonNekoand藍+85CD 69f5d884da fix: add tool calls content, check null value (#137)
* fix: add tool calls content, check `null` value

* fix: redundant undefined check

* fix: use the nullish coalescing operator

Co-authored-by: 藍+85CD <50108258+kwaa@users.noreply.github.com>

* fix: revert statement

* fix: bad copy

---------

Co-authored-by: 藍+85CD <50108258+kwaa@users.noreply.github.com>
2025-04-25 14:51:49 +08:00
藍+85CD d8abf7b15b docs: update description 2025-04-24 14:43:29 +08:00
exoticknight fc3ffc4906 fix(stream-text): no toolcall id in chunk while streaming (#135) 2025-04-23 22:41:19 +08:00
藍+85CD 4e55d9c064 chore: release v0.2.0-beta.4 2025-04-23 19:29:30 +08:00
藍+85CD 92c05a50ec chore: release v0.2.0-beta.3 2025-04-03 19:35:02 +08:00
藍+85CD 99bf128ecf fix(stream-text): fix stream options key naming 2025-04-03 12:02:40 +08:00
藍+85CD 96e63a1ba1 chore(model): remove useless content type 2025-04-03 11:56:50 +08:00
藍+85CD b9f359cb8f chore: release v0.2.0-beta.2 2025-03-30 21:43:27 +08:00
藍+85CD 53352a1534 fix: use pkgroll instead of tsup, fix pre-compile types 2025-03-30 21:30:15 +08:00
a72e88b532 fix: error handling when return 200 (#124)
* fix: handle 200 error

* fix: choices

* chore: responseJSON

* Update packages/generate-text/src/index.ts

* Update packages/shared/src/utils/response-json.ts

* Update packages/shared/src/utils/response-json.ts

* fix: lint error

---------

Co-authored-by: Neko <neko@ayaka.moe>
Co-authored-by: 藍+85CD <50108258+kwaa@users.noreply.github.com>
2025-03-28 22:44:56 +08:00
藍+85CDandNeko f51578f9b0 feat: new package generate-image (#123)
* feat: new package `generate-image`

* fix(generate-image): url path

* fix: lint errors

* docs: add generate-image

* chore(xsai): update exports

---------

Co-authored-by: Neko <neko@ayaka.moe>
2025-03-27 20:22:13 +08:00
藍+85CD de95e90b0f chore: release v0.2.0-beta.1 2025-03-24 22:30:47 +08:00
藍+85CD 676a80d2c8 refactor(xsschema)!: remove alias for more clarity 2025-03-24 22:23:14 +08:00
藍+85CD eceb7d91b5 feat(tool): returns schema (#118)
* feat(tool): returns schema

* chore(tool): update test

* chore(shared-chat): move types

* docs(tool): add returns example

* fix(shared-chat): clean returns

* fix(compat): use generics

* docs(tool): fix example

* fix(compat): add generics
2025-03-24 22:19:41 +08:00
exoticknight 2b72e82a74 refactor(stream-text): use parsedArgs and toolName from executeTool (#117)
* fix(stream-text): use parsedArgs and toolName from executeTool in toolResults

* fix(stream-text): streamline parsed arguments handling in tool calls
2025-03-21 23:48:39 +08:00
藍+85CD 4fd6e488f3 feat(xsschema): support effect schema (#115)
* feat(xsschema): support effect schema

* docs(xsschema): typo
2025-03-21 16:11:18 +08:00
藍+85CD 547c6cfe75 refactor: move xs packages to packages-top 2025-03-20 15:52:10 +08:00
藍+85CD fc5446e8a5 chore: release v0.1.3 2025-03-13 19:35:32 +08:00
藍+85CD ededb40469 feat(stream-text): return stepType, finishReason (#106)
* refactor: move step type to shared-chat

* refactor: move determine-step-type to shared-chat

* refactor: move execute-tool to shared-chat

* refactor(stream-text): use execute-tool

* refactor(stream-text): return step-type, finish-reason

* refactor(shared-chat): move wrap-tool-result to internal

* refactor(shared-chat): update determine step type

* refactor(stream-text): update loop check

* refactor(generate-text): remove finish length handle

* fix: check finish reason

* chore(generate-text/test): update snapshot

* fix(shared-chat): fix max steps check

* fix(stream-text): revert changes
2025-03-13 16:32:15 +08:00
藍+85CD d1fb5b2ae1 refactor: simplify fetch type (#104) 2025-03-12 20:37:43 +08:00
Kai 5846f59a8c refactor(generate-text): align stepType as vercel ai-sdk (#102)
* align stepType state as vercel ai-sdk

* refactor and fix unit test

* refactor to reduce method complexity
2025-03-12 20:02:41 +08:00
藍+85CD 0fd6b6e95e feat: new package @xsai-ext/compat (#94)
* chore: new experimental package `@xsai-ext/compat`

* chore(scripts): exclude private package

* fix(xsai): export shared

* feat(compat): add embed

* chore(compat): update embed

* feat(compat): add generate text

* fix(utils-stream): export types

* fix(compat/embed): export result types

* refactor(compat): unsupported types

* fix(compat): export core message type

* feat(compat): add stream text

* chore(compat): update types

* chore(compat): update version

* feat(compat): support prompt, system

* feat(compat): add {generate,stream}-object

* fix(compat): set stream object return type

* feat(compat): add unsupported utils

* fix(compat): improve convert tools

* chore: add mastra example

* fix(compat/generate-text): export result type

* fix(compat/stream-text): export result type

* chore(compat): mark as public

* docs: add compat

* docs: add verified version

* chore: remove mastra example
2025-03-10 15:34:28 +08:00
藍+85CD 5d2c5a29b2 chore: release v0.1.2 2025-03-07 22:00:15 +08:00
藍+85CDandexoticknight 9ad230c420 feat(tool): support multimodal & object result (#95)
* feat(tool): support object and array result

* chore(tool): update execute type

* feat(stream-text): support multiple result types in tool call results

---------

Co-authored-by: exoticknight <draco.knight0@gmail.com>
2025-03-07 20:09:00 +08:00
藍+85CD bc0a97f3d6 chore: release v0.1.1 2025-03-06 22:08:08 +08:00
藍+85CD 91a7b14e13 docs: add utils (#93)
* docs: add utils

* fix(utils-stream): set return type

* chore(utils-stream): add comment
2025-03-06 22:06:25 +08:00
藍+85CD 36ea9e6528 fix(xsfetch): fix object assign 2025-03-04 20:54:07 +08:00
藍+85CD 499460eb66 refactor(xsfetch): early return (#89) 2025-03-04 20:20:04 +08:00
藍+85CD e10e5d3cac refactor(xsfetch): allow empty user options 2025-03-04 20:14:37 +08:00
junkwarrior87 2d0289002c fix(xsfetch): make retry work, remove the exposure of retryCount (#88) 2025-03-04 20:08:36 +08:00
藍+85CD 4695e0d455 chore: release v0.1.0 2025-03-03 18:09:06 +08:00
藍+85CD a9c3250d5f fix: openai base url 2025-03-03 13:29:26 +08:00
藍+85CD 64afb7a0e7 chore(packages): remove wip 2025-03-02 20:38:03 +08:00
藍+85CD 5afd2c3902 docs(packages): add readme 2025-03-02 17:43:07 +08:00
藍+85CD c26f4c234c chore(deps): move schema library to catalog 2025-03-02 17:07:08 +08:00
藍+85CD 5d901dc219 fix(xsfetch): compatible with global fetch 2025-03-02 17:06:25 +08:00
藍+85CD 41903904f6 refactor(generate-text): onStepFinish allow unknown type (#83) 2025-03-01 22:31:23 +08:00
Neko Ayaka bfe86720d3 chore: release v0.1.0-beta.9 2025-02-27 14:54:26 +08:00
Neko 94cb0688aa feat(embed,shared-provider): export response, extend more provider generics (#82)
Signed-off-by: Neko Ayaka <neko@ayaka.moe>
2025-02-27 13:50:25 +08:00
藍+85CD 75efac0f8e chore: release v0.1.0-beta.8 2025-02-26 22:15:16 +08:00