-
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
174 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
{ | ||
"components": { | ||
"schemas": { | ||
"loadPdfRequest": { | ||
"type": "object", | ||
"required": ["pdf_url"], | ||
"properties": { | ||
"pdf_url": { | ||
"type": "string", | ||
"format": "uri", | ||
"description": "The temporary URL of the PDF document to load.", | ||
"required": true | ||
} | ||
} | ||
}, | ||
"queryPdfRequest": { | ||
"type": "object", | ||
"required": ["query", "pdf_url"], | ||
"properties": { | ||
"query": { | ||
"type": "string", | ||
"description": "The query or question to ask based on the PDF document.", | ||
"required": true | ||
}, | ||
"pdf_url": { | ||
"type": "string", | ||
"format": "uri", | ||
"description": "The temporary URL of the PDF document that is already loaded.", | ||
"required": true | ||
} | ||
} | ||
}, | ||
"queryPdfResponse": { | ||
"type": "object", | ||
"properties": { | ||
"results": { | ||
"type": "array", | ||
"items": { "type": "string" }, | ||
"description": "The list of text chunks from the PDF document that are relevant to the user's query." | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"info": { | ||
"title": "ChatWithPDF", | ||
"description": "A plugin that allows users to load and query PDF documents or Google Drive documents using ChatGPT. Users must first provide a PDF URL for processing. Once the PDF is loaded, users can query, analyze, or ask questions from that PDF name without needing to specify everytime. User must provide a PDF or Google Drive link that can be publically accessible, only documents can be loaded. The query will be able to extract relevant parts of the document to the users request. The load may take a while to process and if it does not work on the first try, try again, unless you get an error message back. User can only load documents that can be publically accessible on the internet. If they wish to use Google Docs they must first export it as a PDF, upload it to Google Drive then share a link that anybody can access via the link so we can download and process it. And if they wish to upload their document they can instead use service like [Upload Document](https://tmpfiles.org/).", | ||
"version": "v3" | ||
}, | ||
"openapi": "3.0.1", | ||
"paths": { | ||
"/pdf/load": { | ||
"post": { | ||
"operationId": "loadPdf", | ||
"summary": "Load a PDF document", | ||
"requestBody": { | ||
"required": true, | ||
"content": { | ||
"application/json": { "schema": { "$ref": "#/components/schemas/loadPdfRequest" } } | ||
} | ||
}, | ||
"responses": { "200": { "description": "OK" } } | ||
} | ||
}, | ||
"/pdf/query": { | ||
"post": { | ||
"operationId": "queryPdf", | ||
"summary": "Query a loaded PDF document", | ||
"requestBody": { | ||
"required": true, | ||
"content": { | ||
"application/json": { "schema": { "$ref": "#/components/schemas/queryPdfRequest" } } | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"description": "OK", | ||
"content": { | ||
"application/json": { "schema": { "$ref": "#/components/schemas/queryPdfResponse" } } | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"servers": [{ "url": "https://chatwithpdf.sdan.io" }] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters