Skip to content

Commit

Permalink
fix: comment should follow mdx
Browse files Browse the repository at this point in the history
  • Loading branch information
thucpn committed Dec 9, 2024
1 parent c3c2ad2 commit f1ed6df
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 9 deletions.
6 changes: 0 additions & 6 deletions apps/next/scripts/generate-docs.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,6 @@ function transformOutput(file, content) {
const fileName = path.basename(file);
let title = fileName.split(".")[0];
if (title === "index") title = "LlamaIndex API Reference";

// FIXME: need to fix character issue in typedoc later
const excludeFiles = ["ContextChatEngine", "HTMLReader", "ImageReader"];
if (excludeFiles.includes(title))
return `---\ntitle: ${title}\n---\n\nEmpty Content`;

return `---\ntitle: ${title}\n---\n\n${content}`;
}

Expand Down
3 changes: 2 additions & 1 deletion packages/core/src/chat-engine/context-chat-engine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ import type { ContextGenerator } from "./type";

/**
* ContextChatEngine uses the Index to get the appropriate context for each query.
* The context is stored in the system prompt, and the chat history is chunk: ChatResponseChunk, nodes?: NodeWithScore<import("/Users/marcus/code/llamaindex/LlamaIndexTS/packages/core/src/Node").Metadata>[], nodes?: NodeWithScore<import("/Users/marcus/code/llamaindex/LlamaIndexTS/packages/core/src/Node").Metadata>[]lowing the appropriate context to be surfaced for each query.
* The context is stored in the system prompt, and the chat history is chunk,
* allowing the appropriate context to be surfaced for each query.
*/
export class ContextChatEngine extends PromptMixin implements BaseChatEngine {
chatModel: LLM;
Expand Down
2 changes: 1 addition & 1 deletion packages/readers/src/html.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export class HTMLReader extends FileReader<Document> {
* Public method for this reader.
* Required by BaseReader interface.
* @param fileContent - The content of the file.
* @returns Promise<Document[]> A Promise object, eventually yielding zero or one Document parsed from the HTML content of the specified file.
* @returns `Promise<Document[]>` A Promise object, eventually yielding zero or one Document parsed from the HTML content of the specified file.
*/
async loadDataAsContent(fileContent: Uint8Array): Promise<Document[]> {
const decoder = new TextDecoder("utf-8");
Expand Down
2 changes: 1 addition & 1 deletion packages/readers/src/image.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export class ImageReader extends FileReader<ImageDocument> {
* Public method for this reader.
* Required by BaseReader interface.
* @param fileContent - The content of the file.
* @returns Promise<Document[]> A Promise object, eventually yielding zero or one ImageDocument of the specified file.
* @returns `Promise<Document[]>` A Promise object, eventually yielding zero or one ImageDocument of the specified file.
*/
async loadDataAsContent(fileContent: Uint8Array): Promise<ImageDocument[]> {
const blob = new Blob([fileContent]);
Expand Down

0 comments on commit f1ed6df

Please sign in to comment.