opentiny / opentiny/tiny-editor

🐛 [Bug]: AI 功能完全不可用,代码里写死了本地 Ollama 的接口地址 /api/generate

Open
#321 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
TypeScript
Stars
535
Forks
71
Avg merge
6h 50m
Merged PRs (30d)
2

Description

Version

latest

Link to minimal reproduction

尝试配置 DeepSeek 的 apikey,接口 404 了。

看了下 AI 模块的源码,发现请求 AI 的接口时写死了本地 Ollama 接口 /api/generate,而用户真实的使用场景不可以使用本地大模型的。

问题源码:https://github.com/opentiny/tiny-editor/blob/cd20ab5b06919765ba3d1d219f1571296a288313/packages/fluent-editor/src/modules/ai/index.ts#L645

Image
Step to reproduce

如上说明

What is expected

No response

What is actually happening

No response

What is your project name

Wiki

Any additional comments (optional)

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in packages/fluent-editor/src/modules/ai/index.ts around line 645 and inspect how the AI request is assembled, then reproduce the reported DeepSeek API-key configuration and 404 response. Done should mean the AI module no longer depends on the hard-coded local Ollama /api/generate endpoint and the configured service can be contacted successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
ollama, typescript
Domain
ai, api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.