forked from cogentapps/chat-with-gpt
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add typescript tokenizer and better chat trimmer
- Loading branch information
1 parent
216ecd5
commit b6881c6
Showing
24 changed files
with
477 additions
and
1,362 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,37 @@ | ||
const cracoWasm = require("craco-wasm"); | ||
|
||
/* | ||
{ | ||
"plugins": [ | ||
[ | ||
"formatjs", | ||
{ | ||
"idInterpolationPattern": "[sha512:contenthash:base64:6]", | ||
"ast": true | ||
} | ||
] | ||
] | ||
} | ||
*/ | ||
const webpack = require("webpack"); | ||
|
||
module.exports = { | ||
plugins: [ | ||
cracoWasm(), | ||
], | ||
eslint: { | ||
enable: false | ||
}, | ||
babel: { | ||
plugins: [ | ||
cracoWasm(), | ||
], | ||
eslint: { | ||
enable: false | ||
[ | ||
'formatjs', | ||
{ | ||
removeDefaultMessage: false, | ||
idInterpolationPattern: '[sha512:contenthash:base64:6]', | ||
ast: true | ||
} | ||
] | ||
] | ||
}, | ||
webpack: { | ||
configure: { | ||
resolve: { | ||
fallback: { | ||
buffer: require.resolve("buffer"), | ||
}, | ||
}, | ||
plugins: [ | ||
new webpack.ProvidePlugin({ | ||
Buffer: ["buffer", "Buffer"], | ||
}), | ||
], | ||
}, | ||
babel: { | ||
plugins: [ | ||
[ | ||
'formatjs', | ||
{ | ||
removeDefaultMessage: false, | ||
idInterpolationPattern: '[sha512:contenthash:base64:6]', | ||
ast: true | ||
} | ||
] | ||
] | ||
} | ||
}, | ||
} |
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
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 was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.