Przeglądaj źródła

Don't use ',' (U+FF0C) but ', ' (U+2C U+20) (#8063)

The Unicode codepoint ',' (U+FF0C) is meant to be used in Chinese text,
but this is English text. It looks like a comma followed by a space, but
isn't. Of course I didn't change actual Chinese text.

### What problem does this PR solve?

Mixup of Unicode characters. This is probably unnoticed by most users,
but I wonder if screen readers would read it out differently or if LLMs
would trip up on it.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
- [ ] New Feature (non-breaking change which adds functionality)
- [x] Documentation Update
- [ ] Refactoring
- [ ] Performance Improvement
- [ ] Other (please describe):
tags/v0.19.1
Mathias Panzenböck 5 miesięcy temu
rodzic
commit
a374816fb2
No account linked to committer's email address

+ 3
- 3
docs/references/http_api_reference.md Wyświetl plik

- `document_id`: (*Path parameter*) - `document_id`: (*Path parameter*)
The ID of the document to update. The ID of the document to update.
- `"name"`: (*Body parameter*), `string` - `"name"`: (*Body parameter*), `string`
- `"meta_fields"`: (*Body parameter*) `dict[str, Any]` The meta fields of the document.
- `"meta_fields"`: (*Body parameter*), `dict[str, Any]` The meta fields of the document.
- `"chunk_method"`: (*Body parameter*), `string` - `"chunk_method"`: (*Body parameter*), `string`
The parsing method to apply to the document: The parsing method to apply to the document:
- `"naive"`: General - `"naive"`: General
"id": "4606b4ec87ad11efbc4f0242ac120006", "id": "4606b4ec87ad11efbc4f0242ac120006",
"messages": [ "messages": [
{ {
"content": "Hi! I am your assistantcan I help you?",
"content": "Hi! I am your assistant, can I help you?",
"role": "assistant" "role": "assistant"
} }
], ],
"id": "578d541e87ad11ef96b90242ac120006", "id": "578d541e87ad11ef96b90242ac120006",
"messages": [ "messages": [
{ {
"content": "Hi! I am your assistantcan I help you?",
"content": "Hi! I am your assistant, can I help you?",
"role": "assistant" "role": "assistant"
} }
], ],

+ 2
- 2
docs/references/python_api_reference.md Wyświetl plik

- Success: A `Session` object containing the following attributes: - Success: A `Session` object containing the following attributes:
- `id`: `str` The auto-generated unique identifier of the created session. - `id`: `str` The auto-generated unique identifier of the created session.
- `name`: `str` The name of the created session. - `name`: `str` The name of the created session.
- `message`: `list[Message]` The opening message of the created session. Default: `[{"role": "assistant", "content": "Hi! I am your assistantcan I help you?"}]`
- `message`: `list[Message]` The opening message of the created session. Default: `[{"role": "assistant", "content": "Hi! I am your assistant, can I help you?"}]`
- `chat_id`: `str` The ID of the associated chat assistant. - `chat_id`: `str` The ID of the associated chat assistant.
- Failure: `Exception` - Failure: `Exception`




- Success: A `Session` object containing the following attributes: - Success: A `Session` object containing the following attributes:
- `id`: `str` The auto-generated unique identifier of the created session. - `id`: `str` The auto-generated unique identifier of the created session.
- `message`: `list[Message]` The messages of the created session assistant. Default: `[{"role": "assistant", "content": "Hi! I am your assistantcan I help you?"}]`
- `message`: `list[Message]` The messages of the created session assistant. Default: `[{"role": "assistant", "content": "Hi! I am your assistant, can I help you?"}]`
- `agent_id`: `str` The ID of the associated agent. - `agent_id`: `str` The ID of the associated agent.
- Failure: `Exception` - Failure: `Exception`



+ 2
- 2
sdk/python/ragflow_sdk/modules/session.py Wyświetl plik

def __init__(self, rag, res_dict): def __init__(self, rag, res_dict):
self.id = None self.id = None
self.name = "New session" self.name = "New session"
self.messages = [{"role": "assistant", "content": "Hi! I am your assistantcan I help you?"}]
self.messages = [{"role": "assistant", "content": "Hi! I am your assistant, can I help you?"}]
for key, value in res_dict.items(): for key, value in res_dict.items():
if key == "chat_id" and value is not None: if key == "chat_id" and value is not None:
self.chat_id = None self.chat_id = None


class Message(Base): class Message(Base):
def __init__(self, rag, res_dict): def __init__(self, rag, res_dict):
self.content = "Hi! I am your assistantcan I help you?"
self.content = "Hi! I am your assistant, can I help you?"
self.reference = None self.reference = None
self.role = "assistant" self.role = "assistant"
self.prompt = None self.prompt = None

+ 1
- 1
web/src/interfaces/request/base.ts Wyświetl plik

export interface IPaginationRequestBody { export interface IPaginationRequestBody {
keywords?: string; keywords?: string;
page?: number; page?: number;
page_size?: number; // name|create|doc_num|create_time|update_timedefault:create_time
page_size?: number; // name|create|doc_num|create_time|update_time, default:create_time
orderby?: string; orderby?: string;
desc?: string; desc?: string;
} }

Ładowanie…
Anuluj
Zapisz