Add connector strategy and codex media replies
This commit is contained in:
parent
840b3af2eb
commit
b4d869bd0d
15 changed files with 799 additions and 22 deletions
14
src/connectors/index.js
Normal file
14
src/connectors/index.js
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
const { createLocalCodexConnectorStrategy } = require("./local-codex");
|
||||
|
||||
function createConnectorStrategy(config) {
|
||||
switch (config.type) {
|
||||
case "local-codex":
|
||||
return createLocalCodexConnectorStrategy(config.localCodex);
|
||||
default:
|
||||
throw new Error(`Unsupported connector type: ${config.type}`);
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
createConnectorStrategy,
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue