Skip to content

Commit 9f28104

Browse files
authored
Merge pull request #148 from opentiny/move-think-wrap
refactor: move think wrap form core to chat
2 parents ad83f5e + 21122ea commit 9f28104

4 files changed

Lines changed: 5 additions & 3 deletions

File tree

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
export * from './pattern-extractor';
22
export * from './schema-json-pattern';
33
export * from './stream-pattern-extractor';
4-
export * from './think-tag-wrap-pattern';
54
export * from './common';

packages/frameworks/vue/src/chat/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ export * from './i18n/index.js';
55
export * from './tiny-robot-patch/index.js';
66
export * from './event-emitter.js';
77
export * from './chat-utils.js';
8+
export * from './think-tag-wrap-pattern.js';

packages/frameworks/vue/src/chat/response-handler.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import { IChatMessage, IMessageItem, IStreamDelta, IStreamData, PatternExtractor, ThinkTagWrapPattern } from "@opentiny/genui-sdk-core";
1+
import { IChatMessage, IMessageItem, IStreamDelta, IStreamData, PatternExtractor } from "@opentiny/genui-sdk-core";
2+
import { ThinkTagWrapPattern } from './think-tag-wrap-pattern';
23
import { reactive, toRaw, watch } from "vue";
34
import { v4 as uuidv4 } from 'uuid';
45
import { emitter } from './event-emitter';

packages/core/src/stream-pattern-extractor/think-tag-wrap-pattern.ts renamed to packages/frameworks/vue/src/chat/think-tag-wrap-pattern.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import { getPartialStartRegString } from "./common";
1+
import { getPartialStartRegString } from "@opentiny/genui-sdk-core";
2+
23
export class ThinkTagWrapPattern {
34
protected thinkStartFlag: string = '<think>';
45
protected thinkEndFlag: string = '</think>';

0 commit comments

Comments
 (0)