├── .eslintignore ├── .eslintrc.js ├── .github └── workflows │ ├── pull_request_ci.yml │ └── thoth-core-release.yml ├── .gitignore ├── .nvmrc ├── .prettierrc.json ├── .vscode ├── launch.json └── settings.json ├── .yarn └── releases │ └── yarn-1.18.0.cjs ├── .yarnrc ├── CONTRIBUTORS.txt ├── LICENSE ├── README.md ├── appspec.yml ├── docs ├── .gitignore ├── LICENSE ├── README.md ├── archive │ ├── tutorial-basics │ │ ├── _category_.json │ │ ├── congratulations.md │ │ ├── create-a-blog-post.md │ │ ├── create-a-document.md │ │ ├── create-a-page.md │ │ ├── deploy-your-site.md │ │ └── markdown-features.mdx │ └── tutorial-extras │ │ ├── _category_.json │ │ ├── manage-docs-versions.md │ │ └── translate-your-site.md ├── babel.config.js ├── blog │ ├── 2019-05-28-first-blog-post.md │ ├── 2019-05-29-long-blog-post.md │ ├── 2021-08-01-mdx-blog-post.mdx │ ├── 2021-08-26-welcome │ │ ├── docusaurus-plushie-banner.jpeg │ │ └── index.md │ └── authors.yml ├── docs │ ├── core-concepts │ │ ├── BackPropagation.md │ │ ├── ConceptsOverview.md │ │ ├── FewShots.md │ │ ├── FlowBasedProgramming.md │ │ ├── LogicFlow.md │ │ ├── TriggerControlFlow.md │ │ ├── _category_.json │ │ └── nodes.md │ ├── creators │ │ ├── _category_.json │ │ ├── apikey │ │ │ ├── CreateApiKey.md │ │ │ ├── DestroyApiKey.md │ │ │ ├── PostRequest.md │ │ │ ├── TestingWithPostman.md │ │ │ ├── UsingApiKey.md │ │ │ └── _category_.json │ │ ├── gettingStarted │ │ │ ├── CallingASpell.md │ │ │ ├── ConnectingComponents.md │ │ │ ├── CreatorWelcome.md │ │ │ ├── DeployASpell.md │ │ │ ├── FirstFewshot.md │ │ │ ├── MakingASpell.md │ │ │ ├── WorkingWithState.md │ │ │ └── _category_.json │ │ ├── templates │ │ │ └── _category_.json │ │ └── userInterface │ │ │ ├── ComponentSelector.md │ │ │ ├── Console.md │ │ │ ├── Help.md │ │ │ ├── Layout.md │ │ │ ├── Overview.md │ │ │ ├── SpellComposer.md │ │ │ ├── StateManager.md │ │ │ ├── TextEditor.md │ │ │ └── _category_.json │ ├── developers │ │ ├── _category_.json │ │ ├── architecture overview │ │ │ ├── Architecture.md │ │ │ ├── Contexts.md │ │ │ ├── InspectorControls.md │ │ │ ├── Layouts.md │ │ │ ├── OperationalTransforms.md │ │ │ ├── Plugins.md │ │ │ ├── ReteEditor.md │ │ │ ├── State.md │ │ │ ├── ThothInterface.md │ │ │ ├── WorkspacesAndTabs.md │ │ │ ├── _category_.json │ │ │ └── pubsub.md │ │ ├── getting started │ │ │ ├── _category_.json │ │ │ ├── installingThoth.md │ │ │ └── intro.md │ │ └── packageOverview │ │ │ ├── StargateDesignSystem.md │ │ │ ├── _category_.json │ │ │ ├── thoth-client-core.md │ │ │ ├── thoth-client.md │ │ │ ├── thoth-core.md │ │ │ ├── thoth-server-core.md │ │ │ └── thoth-server.md │ ├── intro.md │ └── notes.md ├── docusaurus.config.js ├── package.json ├── sidebars.js ├── src │ ├── components │ │ └── HomepageFeatures │ │ │ ├── ThothDemo.js │ │ │ ├── index.js │ │ │ └── styles.module.css │ ├── css │ │ └── custom.css │ └── pages │ │ ├── index.js │ │ ├── index.module.css │ │ └── markdown-page.md ├── static │ ├── .nojekyll │ └── img │ │ ├── Thoth-Screen.png │ │ ├── apikey │ │ ├── api-key-copied.png │ │ ├── api-key-page.png │ │ ├── created-api-key.png │ │ ├── current-api-key.png │ │ ├── generate-api-key.png │ │ ├── postman-add-to-header.png │ │ ├── postman-apikey-input.png │ │ ├── postman-authorization-tab.png │ │ ├── postman-body-input.png │ │ ├── postman-body-tab.png │ │ ├── postman-key.png │ │ ├── postman-new-tab.png │ │ ├── postman-overview.png │ │ ├── postman-request-type.png │ │ ├── postman-send.png │ │ ├── postman-url-input.png │ │ ├── postman-value.png │ │ ├── settings-api-key.png │ │ ├── settings-menu.png │ │ └── user-icon.png │ │ ├── docusaurus.png │ │ ├── favicon.ico │ │ ├── logo.svg │ │ ├── thoth-logo.png │ │ ├── tutorial │ │ ├── docsVersionDropdown.png │ │ └── localeDropdown.png │ │ ├── undraw_docusaurus_mountain.svg │ │ ├── undraw_docusaurus_react.svg │ │ └── undraw_docusaurus_tree.svg └── yarn.lock ├── jsconfig.json ├── lerna.json ├── model-notes.md ├── netlify └── plugins │ ├── conditional-canary │ ├── index.js │ └── manifest.yml │ └── staging-canary │ ├── index.js │ └── manifest.yml ├── ot-notes.md ├── package-lock.json ├── package.json ├── packages ├── client │ ├── .env │ ├── .env.example │ ├── .eslintignore │ ├── .eslintrc.js │ ├── .gitignore │ ├── .npmrc │ ├── README.md │ ├── TODO.md │ ├── canister_ids.json │ ├── certs │ │ ├── cert.pem │ │ └── key.pem │ ├── dfx.json │ ├── index.html │ ├── netlify.toml │ ├── package.json │ ├── public │ │ ├── _redirects │ │ ├── favicon.ico │ │ ├── logo192.png │ │ ├── logo512.png │ │ ├── manifest.json │ │ └── robots.txt │ ├── scripts │ │ ├── engine.ts │ │ ├── module.ts │ │ ├── package-lock.json │ │ ├── package.json │ │ ├── spell.ts │ │ └── tsconfig.json │ ├── src │ │ ├── App.css │ │ ├── App.css.d.ts │ │ ├── App.tsx │ │ ├── components │ │ │ ├── Accordion │ │ │ │ ├── accordion-overrides.css │ │ │ │ ├── accordion-overrides.css.d.ts │ │ │ │ ├── accordion.module.css │ │ │ │ ├── accordion.module.css.d.ts │ │ │ │ └── index.tsx │ │ │ ├── Button │ │ │ │ └── button.module.css │ │ │ ├── Chip │ │ │ │ ├── Chip.tsx │ │ │ │ ├── chip.module.css │ │ │ │ └── chip.module.css.d.ts │ │ │ ├── Icon │ │ │ │ ├── Icon.tsx │ │ │ │ ├── Lock.svg │ │ │ │ ├── account.svg │ │ │ │ ├── add.svg │ │ │ │ ├── ankh.svg │ │ │ │ ├── bird.svg │ │ │ │ ├── close.svg │ │ │ │ ├── cloth.svg │ │ │ │ ├── cup.svg │ │ │ │ ├── dangerTrash.svg │ │ │ │ ├── feathers.svg │ │ │ │ ├── fewshot.svg │ │ │ │ ├── folder.svg │ │ │ │ ├── hand.svg │ │ │ │ ├── icon.module.css │ │ │ │ ├── icon.module.css.d.ts │ │ │ │ ├── info.svg │ │ │ │ ├── merge.svg │ │ │ │ ├── minus.svg │ │ │ │ ├── moon.svg │ │ │ │ ├── newnode.svg │ │ │ │ ├── node-lock.svg │ │ │ │ ├── pause.svg │ │ │ │ ├── person.svg │ │ │ │ ├── play-print.svg │ │ │ │ ├── play.svg │ │ │ │ ├── properties.svg │ │ │ │ ├── refresh.svg │ │ │ │ ├── search.svg │ │ │ │ ├── seive.svg │ │ │ │ ├── snake.svg │ │ │ │ ├── state-read.svg │ │ │ │ ├── state-write.svg │ │ │ │ ├── state.svg │ │ │ │ ├── stop-sign.svg │ │ │ │ ├── stop.svg │ │ │ │ ├── switch.svg │ │ │ │ ├── temperature.svg │ │ │ │ ├── text.svg │ │ │ │ ├── tiles.svg │ │ │ │ ├── time.svg │ │ │ │ ├── trash.svg │ │ │ │ ├── warn.svg │ │ │ │ ├── water-play.svg │ │ │ │ ├── water-run.svg │ │ │ │ └── water.svg │ │ │ ├── Input │ │ │ │ ├── Input.tsx │ │ │ │ └── input.module.css │ │ │ ├── LoadingScreen │ │ │ │ ├── LoadingScreen.jsx │ │ │ │ └── ankh.gif │ │ │ ├── MenuBar │ │ │ │ ├── MenuBar.tsx │ │ │ │ ├── menuBar.module.css │ │ │ │ ├── menuBar.module.css.d.ts │ │ │ │ └── thoth.png │ │ │ ├── Mint │ │ │ │ ├── Mint.tsx │ │ │ │ ├── dabStuff.css │ │ │ │ └── dabStuff.css.d.ts │ │ │ ├── Modal │ │ │ │ ├── Modal.jsx │ │ │ │ ├── modal.module.css │ │ │ │ └── modal.module.css.d.ts │ │ │ ├── Modals │ │ │ │ ├── AddClientSettings.tsx │ │ │ │ ├── AddScope.tsx │ │ │ │ ├── AgentModal.tsx │ │ │ │ ├── Config.tsx │ │ │ │ ├── DeleteModal.tsx │ │ │ │ ├── DeployModal.jsx │ │ │ │ ├── EditSpellModal.tsx │ │ │ │ ├── ExampleModal.jsx │ │ │ │ ├── InfoModal.tsx │ │ │ │ ├── SaveAsModal.tsx │ │ │ │ ├── SearchCorpus │ │ │ │ │ ├── ContentObjEditModal.tsx │ │ │ │ │ ├── DocumentAddModal.tsx │ │ │ │ │ ├── DocumentDeleteModal.tsx │ │ │ │ │ ├── DocumentEditModal.tsx │ │ │ │ │ ├── StoreAddEditModal.tsx │ │ │ │ │ └── StoreDeleteModal.tsx │ │ │ │ ├── index.ts │ │ │ │ ├── loginModal.module.css.d.ts │ │ │ │ ├── modalForms.module.css │ │ │ │ └── modalForms.module.css.d.ts │ │ │ ├── Node │ │ │ │ ├── Node.module.css │ │ │ │ ├── Node.module.css.d.ts │ │ │ │ └── Node.tsx │ │ │ ├── Panel │ │ │ │ ├── Panel.tsx │ │ │ │ ├── panel.module.css │ │ │ │ └── panel.module.css.d.ts │ │ │ ├── PlugWallet │ │ │ │ ├── PlugWallet.tsx │ │ │ │ ├── plugWallet.css │ │ │ │ └── plugWallet.css.d.ts │ │ │ ├── RequireAuth │ │ │ │ └── RequireAuth.tsx │ │ │ ├── Select │ │ │ │ ├── Select.tsx │ │ │ │ ├── select.module.css │ │ │ │ └── select.module.css.d.ts │ │ │ ├── Switch │ │ │ │ └── Switch.tsx │ │ │ ├── TabBar │ │ │ │ ├── CreateTab.tsx │ │ │ │ ├── LoginTab.tsx │ │ │ │ ├── TabBar.tsx │ │ │ │ ├── tabBar.module.css │ │ │ │ └── tabBar.module.css.d.ts │ │ │ ├── TabLayout │ │ │ │ ├── TabLayout.jsx │ │ │ │ ├── TabLayout.module.css │ │ │ │ └── TabLayout.module.css.d.ts │ │ │ ├── ThothPage │ │ │ │ ├── ThothPageWrapper.tsx │ │ │ │ ├── pagewrapper.module.css │ │ │ │ └── pagewrapper.module.css.d.ts │ │ │ ├── Toolbar │ │ │ │ ├── Toolbar.tsx │ │ │ │ └── toolbar.module.css │ │ │ ├── Window │ │ │ │ ├── Window.tsx │ │ │ │ ├── WindowToolbar.tsx │ │ │ │ ├── window.module.css │ │ │ │ └── window.module.css.d.ts │ │ │ └── z. Don't use │ │ │ │ └── TextInput │ │ │ │ ├── TextInput.tsx │ │ │ │ └── textinput.module.css │ │ ├── config.d.ts │ │ ├── config.ts │ │ ├── contexts │ │ │ ├── AppProviders.tsx │ │ │ ├── AuthProvider.tsx │ │ │ ├── FeathersProvider.tsx │ │ │ ├── ModalProvider.jsx │ │ │ ├── ModuleProvider.tsx.bak │ │ │ ├── PlugProvider.tsx │ │ │ ├── PubSubProvider.tsx │ │ │ ├── SharedbProvider.tsx │ │ │ ├── TabManagerProvider.jsx │ │ │ ├── ToastProvider.jsx │ │ │ └── WebSocketProvider.tsx │ │ ├── data │ │ │ ├── chains │ │ │ │ └── default.ts │ │ │ ├── config │ │ │ │ ├── clientSettings.ts │ │ │ │ ├── configData.ts │ │ │ │ └── scopedata.ts │ │ │ ├── graphs │ │ │ │ └── default.ts │ │ │ └── layouts │ │ │ │ └── defaultLayout.json │ │ ├── design-globals │ │ │ ├── design-globals.css │ │ │ └── design-globals.css.d.ts │ │ ├── global.d.ts │ │ ├── grid.png │ │ ├── helpers │ │ │ └── Expire.ts │ │ ├── hooks │ │ │ └── useQuery.ts │ │ ├── index.tsx │ │ ├── react-app-env.d.ts │ │ ├── reportWebVitals.js │ │ ├── screens │ │ │ ├── Admin │ │ │ │ ├── Layout │ │ │ │ │ ├── index.module.css.d.ts │ │ │ │ │ └── index.tsx │ │ │ │ ├── common │ │ │ │ │ ├── Search.tsx │ │ │ │ │ ├── Table.tsx │ │ │ │ │ └── Variable │ │ │ │ │ │ └── column.ts │ │ │ │ ├── component │ │ │ │ │ ├── ActionsModal.tsx │ │ │ │ │ ├── Config │ │ │ │ │ │ └── index.tsx │ │ │ │ │ ├── FilterModal.tsx │ │ │ │ │ ├── Scope │ │ │ │ │ │ └── index.tsx │ │ │ │ │ └── clientSetting │ │ │ │ │ │ └── index.tsx │ │ │ │ └── routes │ │ │ │ │ └── index.tsx │ │ │ ├── Calendar │ │ │ │ ├── Calendar.tsx │ │ │ │ ├── DayLabels.tsx │ │ │ │ ├── calendar.css │ │ │ │ └── calendar.css.d.ts │ │ │ ├── HomeScreen │ │ │ │ ├── HomeScreen.tsx │ │ │ │ ├── components │ │ │ │ │ ├── FileInput.jsx │ │ │ │ │ ├── ProjectRow.tsx │ │ │ │ │ ├── TemplatePanel.jsx │ │ │ │ │ └── VideoInput.jsx │ │ │ │ ├── empty.png │ │ │ │ ├── enki.png │ │ │ │ ├── homeScreen.module.css │ │ │ │ ├── homeScreen.module.css.d.ts │ │ │ │ ├── lang.png │ │ │ │ ├── screens │ │ │ │ │ ├── AllProjects.jsx │ │ │ │ │ ├── CreateNew.tsx │ │ │ │ │ ├── OpenProject.tsx │ │ │ │ │ └── spells │ │ │ │ │ │ └── default.ts │ │ │ │ └── version-banner-0.0.0beta.jpg │ │ │ └── Thoth │ │ │ │ ├── Thoth.tsx │ │ │ │ ├── components │ │ │ │ └── EventHandler.tsx │ │ │ │ ├── thoth.module.css │ │ │ │ └── thoth.module.css.d.ts │ │ ├── services │ │ │ └── game-api │ │ │ │ ├── enki.ts │ │ │ │ └── text.ts │ │ ├── speechUtils.d.ts │ │ ├── speechUtils.ts │ │ ├── state │ │ │ ├── admin │ │ │ │ ├── clientS │ │ │ │ │ ├── clientService.ts │ │ │ │ │ └── clientState.ts │ │ │ │ ├── config │ │ │ │ │ ├── configService.ts │ │ │ │ │ └── configState.ts │ │ │ │ └── scope │ │ │ │ │ ├── scopeService.ts │ │ │ │ │ └── scopeState.ts │ │ │ ├── api │ │ │ │ ├── api.ts │ │ │ │ ├── spells.ts │ │ │ │ └── visualGenerationsApi.ts │ │ │ ├── gameState.ts │ │ │ ├── hooks.ts │ │ │ ├── preferences.ts │ │ │ ├── reducers.ts │ │ │ ├── store.ts │ │ │ └── tabs.ts │ │ ├── types.ts │ │ ├── utils │ │ │ ├── AsyncStorage.ts │ │ │ ├── debounce.js │ │ │ ├── enkiHelpers.js │ │ │ ├── huggingfaceHelper.js │ │ │ ├── json0.ts │ │ │ └── uuid.ts │ │ ├── wdyr.ts │ │ └── workspaces │ │ │ ├── contexts │ │ │ ├── EditorProvider.tsx │ │ │ ├── InspectorProvider.tsx │ │ │ ├── LayoutProvider.tsx │ │ │ ├── ThothInterfaceProvider.tsx │ │ │ └── WorkspaceProvider.jsx │ │ │ ├── index.tsx │ │ │ └── spells │ │ │ ├── DataControls │ │ │ ├── CodeControl.jsx │ │ │ ├── DataControls.jsx │ │ │ ├── DropdownSelect.tsx │ │ │ ├── EnkiSelect.jsx │ │ │ ├── Info.jsx │ │ │ ├── Input.jsx │ │ │ ├── InputGenerator.tsx │ │ │ ├── LongTextControl.jsx │ │ │ ├── ModelSelect.jsx │ │ │ ├── OutputGenerator.jsx │ │ │ ├── PlaytestControl.tsx │ │ │ ├── SocketGenerator.jsx │ │ │ ├── SpellSelect.tsx │ │ │ ├── SwitchControl.tsx │ │ │ ├── datacontrols.module.css │ │ │ ├── datacontrols.module.css.d.ts │ │ │ └── index.jsx │ │ │ ├── components │ │ │ └── WindowMessage.jsx │ │ │ ├── index.tsx │ │ │ └── windows │ │ │ ├── ContentObject.tsx │ │ │ ├── DebugConsole │ │ │ └── index.tsx │ │ │ ├── EditorWindow │ │ │ ├── Deployment.tsx │ │ │ ├── Minting.tsx │ │ │ ├── editorwindow.module.css │ │ │ ├── editorwindow.module.css.d.ts │ │ │ └── index.jsx │ │ │ ├── EntityManagerWindow.tsx │ │ │ ├── EntityWindow.tsx │ │ │ ├── EventManager │ │ │ ├── EventTable.tsx │ │ │ └── index.tsx │ │ │ ├── InspectorWindow.tsx │ │ │ ├── PlaytestWindow.tsx │ │ │ ├── SearchCorpusDocument.tsx │ │ │ ├── SearchCorpusWindow.tsx │ │ │ ├── SettingsWindow │ │ │ └── index.tsx │ │ │ ├── StateManagerWindow.tsx │ │ │ ├── TextEditorWindow.tsx │ │ │ └── VideoTranscription.tsx │ ├── tsconfig.json │ └── vite.config.js ├── core │ ├── .env │ ├── .env.example │ ├── .eslintignore │ ├── .eslintrc.js │ ├── .gitignore │ ├── .npmignore │ ├── .npmrc │ ├── @types │ │ ├── deepEqual.d.ts │ │ ├── rete-comment-plugin.d.ts │ │ ├── rete-connection-reroute-plugin.d.ts │ │ └── rete-context-menu-plugin.d.ts │ ├── README.md │ ├── data │ │ ├── booleanGateSpell.thoth │ │ ├── booleanGateSpell.ts │ │ ├── codeSpell.thoth │ │ ├── codeSpell.ts │ │ ├── forEachSpell.thoth │ │ ├── forEachSpell.ts │ │ ├── generatorSpell.thoth │ │ ├── generatorSpell.ts │ │ ├── generatorSwitchSpell.thoth │ │ ├── generatorSwitchSpell.ts │ │ ├── imageGeneratorSpell.thoth │ │ ├── imageGeneratorSpell.ts │ │ ├── inputOutputSpell.thoth │ │ ├── inputOutputSpell.ts │ │ ├── joinListSpell.thoth │ │ ├── joinListSpell.ts │ │ ├── parentSpell.thoth │ │ ├── parentSpell.ts │ │ ├── readWriteStateSpell.thoth │ │ ├── readWriteStateSpell.ts │ │ ├── stateReadOutputSpell.thoth │ │ ├── stateReadOutputSpell.ts │ │ ├── stringProcessorSpell.thoth │ │ ├── stringProcessorSpell.ts │ │ ├── subSpell.thoth │ │ ├── subSpell.ts │ │ └── thothInterfaceStub.ts │ ├── index.ts │ ├── jest.config.js │ ├── package.json │ ├── server.ts │ ├── src │ │ ├── components │ │ │ ├── components.ts │ │ │ ├── deprecated │ │ │ │ ├── ActionType.ts │ │ │ │ ├── EntityDetector.ts │ │ │ │ ├── ForEach.ts │ │ │ │ ├── InputField.ts │ │ │ │ ├── ItemDetector.ts │ │ │ │ ├── ModuleInput.ts │ │ │ │ ├── ModuleOutput.ts │ │ │ │ ├── PlaytestInput.ts │ │ │ │ ├── PlaytestPrint.ts │ │ │ │ ├── ProseToScript.ts │ │ │ │ ├── RunInput.ts │ │ │ │ ├── SafetyVerifier.ts │ │ │ │ ├── TenseTransformer.ts │ │ │ │ ├── TimeDetector.ts │ │ │ │ └── oldLatitude │ │ │ │ │ ├── BooleanGate.ts │ │ │ │ │ ├── Code.ts │ │ │ │ │ ├── DifficultyDetector.ts │ │ │ │ │ ├── EnkiTask.ts │ │ │ │ │ ├── ForEach.ts │ │ │ │ │ ├── Generator.ts │ │ │ │ │ ├── Huggingface.ts │ │ │ │ │ ├── Input.ts │ │ │ │ │ ├── JoinList.ts │ │ │ │ │ ├── Output.ts │ │ │ │ │ ├── StateRead.ts │ │ │ │ │ ├── StateWrite.ts │ │ │ │ │ ├── StringProcessor.ts │ │ │ │ │ ├── SwitchGate.ts │ │ │ │ │ ├── TriggerIn.ts │ │ │ │ │ ├── TriggerOut.ts │ │ │ │ │ └── VisualGeneration.ts │ │ │ ├── entities │ │ │ │ ├── AddAgent.ts │ │ │ │ ├── AgentTextCompletion.ts │ │ │ │ ├── CacheManagerDelete.ts │ │ │ │ ├── CacheManagerGet.ts │ │ │ │ ├── CacheManagerSet.ts │ │ │ │ ├── CreateOrGetAgent.ts │ │ │ │ ├── CustomTextCompletion.ts │ │ │ │ ├── EventRecall.ts │ │ │ │ ├── EventStore.ts │ │ │ │ ├── FormOpinionAboutSpeaker.ts │ │ │ │ ├── InputDestructure.ts │ │ │ │ ├── InputRestructure.ts │ │ │ │ ├── OpinionAboutSpeakerGet.ts │ │ │ │ ├── OpinionAboutSpeakerSet.ts │ │ │ │ ├── RandomGreetingResponse.ts │ │ │ │ ├── RandomProfanityResponse.ts │ │ │ │ ├── Request.ts │ │ │ │ ├── SearchArxiv.js │ │ │ │ ├── room3d.ts │ │ │ │ └── roomManager.ts │ │ │ ├── io │ │ │ │ ├── Input.ts │ │ │ │ ├── Output.ts │ │ │ │ ├── TriggerIn.ts │ │ │ │ └── TriggerOut.ts │ │ │ ├── logic │ │ │ │ ├── BooleanGate.ts │ │ │ │ ├── Coallesce.ts │ │ │ │ ├── Code.ts │ │ │ │ ├── ForEach.ts │ │ │ │ ├── IsNullOrUndefined.ts │ │ │ │ ├── IsQuery.ts │ │ │ │ ├── IsVariableTrue.ts │ │ │ │ ├── LogicalOperator.ts │ │ │ │ ├── SwitchGate.ts │ │ │ │ ├── WaitForAll.ts │ │ │ │ └── WhileLoop.ts │ │ │ ├── ml │ │ │ │ ├── ActionType.ts │ │ │ │ ├── Classifier.ts │ │ │ │ ├── DifficultyDetector.ts │ │ │ │ ├── EnkiTask.ts │ │ │ │ ├── EntityDetector.ts │ │ │ │ ├── Generator.ts │ │ │ │ ├── Huggingface.ts │ │ │ │ ├── ItemDetector.ts │ │ │ │ ├── KeywordExtractor.ts │ │ │ │ ├── NamedEntityRecognition.ts │ │ │ │ ├── ProseToScript.ts │ │ │ │ ├── SafetyVerifier.ts │ │ │ │ ├── SentenceMatcher.ts │ │ │ │ ├── SummarizeFacts.ts │ │ │ │ ├── TenseTransformer.ts │ │ │ │ ├── TextToSpeech.ts │ │ │ │ ├── TimeDetector.ts │ │ │ │ └── VisualGeneration.ts │ │ │ ├── search │ │ │ │ ├── DocumentDelete.ts │ │ │ │ ├── DocumentEdit.ts │ │ │ │ ├── DocumentGet.ts │ │ │ │ ├── DocumentSet.ts │ │ │ │ ├── DocumentSetMass.ts │ │ │ │ ├── DocumentStoreGet.ts │ │ │ │ ├── RSSGet.ts │ │ │ │ ├── Search.ts │ │ │ │ └── VectorSearch.ts │ │ │ ├── services │ │ │ │ └── Spell.ts │ │ │ ├── state │ │ │ │ ├── StateRead.ts │ │ │ │ └── StateWrite.ts │ │ │ ├── strings │ │ │ │ ├── ComplexStringMatcher.ts │ │ │ │ ├── JoinList.ts │ │ │ │ ├── ProfanityFilter.ts │ │ │ │ ├── RandomStringFromList.ts │ │ │ │ ├── StringAdder.ts │ │ │ │ ├── StringCombiner.ts │ │ │ │ ├── StringEvaluator.ts │ │ │ │ └── StringProcessor.ts │ │ │ ├── utility │ │ │ │ ├── AlertMessage.ts │ │ │ │ ├── Echo.ts │ │ │ │ ├── InRange.ts │ │ │ │ ├── InputsToJSON.ts │ │ │ │ └── VariableReplacer.ts │ │ │ └── variable │ │ │ │ ├── ArrayVariable.ts │ │ │ │ ├── BooleanVariable.ts │ │ │ │ ├── FewshotVariable.ts │ │ │ │ ├── NumberVariable.ts │ │ │ │ └── StringVariable.ts │ │ ├── controls │ │ │ ├── DisplayControl.tsx │ │ │ ├── RunButtonControl.tsx │ │ │ └── TextInputControl.tsx │ │ ├── dataControls │ │ │ ├── ArrayControl.js │ │ │ ├── BooleanControl.js │ │ │ ├── CodeControl.js │ │ │ ├── CustomDropdown.js │ │ │ ├── DropdownControl.ts │ │ │ ├── EmptyControl.js │ │ │ ├── EnkiThroughputControl.js │ │ │ ├── FewshotControl.js │ │ │ ├── InputControl.js │ │ │ ├── InputControl.ts │ │ │ ├── InputGenerator.js │ │ │ ├── ModelControl.ts │ │ │ ├── NumberControl.js │ │ │ ├── OutputGenerator.js │ │ │ ├── PlaytestControl.js │ │ │ ├── SocketGenerator.ts │ │ │ ├── SpellControl.ts │ │ │ └── SwitchControl.ts │ │ ├── editor.ts │ │ ├── engine.ts │ │ ├── index.ts │ │ ├── plugins │ │ │ ├── areaPlugin │ │ │ │ ├── background.js │ │ │ │ ├── index.js │ │ │ │ ├── restrictor.js │ │ │ │ ├── snap.js │ │ │ │ ├── style.css │ │ │ │ ├── utils.js │ │ │ │ └── zoom-at.js │ │ │ ├── commentPlugin │ │ │ │ ├── comment.js │ │ │ │ ├── draggable.js │ │ │ │ ├── frame-comment.js │ │ │ │ ├── index.js │ │ │ │ ├── inline-comment.js │ │ │ │ ├── manager.js │ │ │ │ ├── style.css │ │ │ │ ├── style.css.d.ts │ │ │ │ └── utils.js │ │ │ ├── debuggerPlugin │ │ │ │ ├── ThothConsole.ts │ │ │ │ └── index.ts │ │ │ ├── displayPlugin │ │ │ │ ├── DisplayControl.jsx │ │ │ │ └── index.js │ │ │ ├── errorPlugin │ │ │ │ └── index.ts │ │ │ ├── historyPlugin │ │ │ │ ├── action.js │ │ │ │ ├── actions │ │ │ │ │ ├── connection.js │ │ │ │ │ └── node.js │ │ │ │ ├── history.js │ │ │ │ └── index.js │ │ │ ├── inspectorPlugin │ │ │ │ ├── DataControl.ts │ │ │ │ ├── Inspector.ts │ │ │ │ ├── dataControls │ │ │ │ │ └── InfoControl.js │ │ │ │ └── index.ts │ │ │ ├── keyCodePlugin │ │ │ │ └── index.ts │ │ │ ├── lifecyclePlugin │ │ │ │ ├── index.ts │ │ │ │ ├── interfaces.ts │ │ │ │ └── utils.ts │ │ │ ├── modulePlugin │ │ │ │ ├── index.ts │ │ │ │ ├── module-manager.ts │ │ │ │ ├── module.ts │ │ │ │ └── utils.ts │ │ │ ├── reactRenderPlugin │ │ │ │ ├── Control.jsx │ │ │ │ ├── Node.jsx │ │ │ │ ├── Socket.jsx │ │ │ │ ├── index.jsx │ │ │ │ ├── styles.css │ │ │ │ ├── styles.css.d.ts │ │ │ │ ├── utils.js │ │ │ │ └── vars.sass │ │ │ ├── selectionPlugin │ │ │ │ └── index.ts │ │ │ ├── socketGenerator │ │ │ │ ├── index.ts │ │ │ │ └── socketManager.ts │ │ │ ├── socketPlugin │ │ │ │ ├── index.ts │ │ │ │ └── socketOverridePlugin.ts │ │ │ └── taskPlugin │ │ │ │ ├── index.ts │ │ │ │ └── task.ts │ │ ├── sockets.ts │ │ ├── spellManager │ │ │ ├── SpellManager.ts │ │ │ ├── SpellRunner.ts │ │ │ ├── configureManager.ts │ │ │ ├── graphHelpers.ts │ │ │ ├── index.ts │ │ │ ├── runGraph.ts │ │ │ └── runSpell.ts │ │ ├── thoth-component.ts │ │ └── utils │ │ │ ├── chainHelpers.ts │ │ │ ├── nodeHelpers.ts │ │ │ ├── runChain.ts │ │ │ └── textClassifier.ts │ ├── test │ │ └── spellManager │ │ │ └── SpellRunner.test.ts │ ├── tsconfig-release.json │ ├── tsconfig.json │ ├── types.ts │ ├── vite.build.js │ └── yarn-error.log ├── runner │ ├── .editorconfig │ ├── .env.example │ ├── .eslintrc.json │ ├── .gitignore │ ├── README.md │ ├── config │ │ ├── default.json │ │ ├── production.json │ │ └── test.json │ ├── jest.config.js │ ├── package.json │ ├── public │ │ ├── favicon.ico │ │ └── index.html │ ├── src │ │ ├── @types │ │ │ └── index.d.ts │ │ ├── api │ │ │ ├── axios.ts │ │ │ ├── completion.ts │ │ │ └── spell.ts │ │ ├── app.hooks.ts │ │ ├── app.ts │ │ ├── authentication.ts │ │ ├── channels.ts │ │ ├── config.ts │ │ ├── declarations.d.ts │ │ ├── index.ts │ │ ├── logger.ts │ │ ├── middleware │ │ │ └── index.ts │ │ ├── services │ │ │ ├── index.ts │ │ │ ├── spell-runner │ │ │ │ ├── spell-runner.class.ts │ │ │ │ ├── spell-runner.hooks.ts │ │ │ │ └── spell-runner.service.ts │ │ │ └── users │ │ │ │ ├── users.class.ts │ │ │ │ ├── users.hooks.ts │ │ │ │ └── users.service.ts │ │ ├── sockets.ts │ │ └── thothInterface.ts │ ├── test │ │ ├── app.test.ts │ │ ├── authentication.test.ts │ │ └── services │ │ │ ├── spell-runner.test.ts │ │ │ └── users.test.ts │ └── tsconfig.json ├── server │ ├── .env │ ├── .eslintignore │ ├── .eslintrc.js │ ├── .gitignore │ ├── .prettierignore │ ├── .prettierrc.json │ ├── @types │ │ ├── cors-anywhere.d.ts │ │ ├── gpt-3-encoder.d.ts │ │ └── ot-json0.d.ts │ ├── README.md │ ├── certs │ │ ├── cert.pem │ │ └── key.pem │ ├── data │ │ └── classifier │ │ │ ├── classifier.json │ │ │ └── training_data.txt │ ├── docker-compose.yml │ ├── ecosystem.config.yml │ ├── env.template │ ├── filters │ │ ├── default_bad_words.txt │ │ ├── default_sensitive_phrases.txt │ │ ├── default_sensitive_words.txt │ │ └── leading_statements.txt │ ├── jest.config.js │ ├── nodemon.json │ ├── package.json │ ├── redis │ │ └── docker-compose.yaml │ ├── src │ │ ├── cacheManager.ts │ │ ├── cors-server.ts │ │ ├── database.ts │ │ ├── databases │ │ │ ├── creatorTools.ts │ │ │ └── models │ │ │ │ ├── authUsers.ts │ │ │ │ ├── calendarEvents.ts │ │ │ │ ├── client_settings.ts │ │ │ │ ├── configuration_setting.ts │ │ │ │ ├── content_objects.ts │ │ │ │ ├── deployedSpells.ts │ │ │ │ ├── documents.ts │ │ │ │ ├── documentstores.ts │ │ │ │ ├── entities.ts │ │ │ │ ├── events.ts │ │ │ │ ├── handled_history.ts │ │ │ │ ├── init-models.ts │ │ │ │ ├── scope_settings.ts │ │ │ │ ├── spells.ts │ │ │ │ └── wikipedia.ts │ │ ├── entities │ │ │ ├── CreateSpellHandler.ts │ │ │ ├── Entity.ts │ │ │ ├── World.ts │ │ │ └── connectors │ │ │ │ ├── browser.ts │ │ │ │ ├── calendar.ts │ │ │ │ ├── discord-voice.ts │ │ │ │ ├── discord.ts │ │ │ │ ├── handleInput.ts │ │ │ │ ├── instagram.ts │ │ │ │ ├── messenger.ts │ │ │ │ ├── reddit.ts │ │ │ │ ├── slack.ts │ │ │ │ ├── telegram.ts │ │ │ │ ├── twilio.ts │ │ │ │ ├── twitter.ts │ │ │ │ ├── utils.ts │ │ │ │ ├── voiceUtils │ │ │ │ ├── VoiceMessage.ts │ │ │ │ ├── addSpeechEvent.ts │ │ │ │ ├── audio.ts │ │ │ │ ├── createVoiceMessage.ts │ │ │ │ ├── googleV2.ts │ │ │ │ ├── speech.ts │ │ │ │ ├── speechOptions.ts │ │ │ │ ├── voiceJoin.ts │ │ │ │ └── witai.ts │ │ │ │ ├── website-reader.ts │ │ │ │ ├── whatsapp.ts │ │ │ │ ├── wikipedia.ts │ │ │ │ ├── xrengine.ts │ │ │ │ └── zoom.ts │ │ ├── entity-server.ts │ │ ├── handleInput.ts │ │ ├── routes.ts │ │ ├── routes │ │ │ ├── auth │ │ │ │ └── login.ts │ │ │ ├── completions │ │ │ │ └── index.ts │ │ │ ├── entities.ts │ │ │ ├── getAudioUrl.ts │ │ │ ├── middleware │ │ │ │ └── auth.ts │ │ │ ├── settings │ │ │ │ ├── index.ts │ │ │ │ └── types.ts │ │ │ └── spells │ │ │ │ ├── index.ts │ │ │ │ ├── module.ts │ │ │ │ ├── runSpell.ts │ │ │ │ ├── testSpells │ │ │ │ ├── actionType.ts │ │ │ │ ├── code.ts │ │ │ │ ├── difficultyDetector.ts │ │ │ │ ├── enkiTask.ts │ │ │ │ ├── entityDetector.ts │ │ │ │ ├── generator.ts │ │ │ │ ├── huggingface.ts │ │ │ │ ├── index.ts │ │ │ │ ├── itemDetector.ts │ │ │ │ ├── proseToScript.ts │ │ │ │ ├── safetyVerifier.ts │ │ │ │ ├── switchGate.ts │ │ │ │ ├── tenseTransformer.ts │ │ │ │ ├── test.json │ │ │ │ └── timeDetector.ts │ │ │ │ └── types.ts │ │ ├── search-server.ts │ │ ├── server.ts │ │ ├── speech-server.ts │ │ ├── systems │ │ │ ├── fileServer.ts │ │ │ ├── googleSpeechToText.ts │ │ │ ├── googleTextToSpeech.ts │ │ │ ├── pythonServer.ts │ │ │ ├── searchCorpus.ts │ │ │ ├── tiktalknet.ts │ │ │ ├── videoConverter.ts │ │ │ └── weaviateClient.ts │ │ ├── types.ts │ │ └── utils │ │ │ ├── CustomError.ts │ │ │ ├── MakeCompletionRequest.ts │ │ │ ├── MakeModelRequest.ts │ │ │ ├── base64.ts │ │ │ ├── crypt.ts │ │ │ ├── respond.ts │ │ │ ├── seed │ │ │ ├── connection.ts │ │ │ ├── defaultRecords.ts │ │ │ └── seeding.ts │ │ │ └── utils.ts │ ├── tsconfig.json │ └── weaviate │ │ ├── classifier_data.json │ │ ├── docker-compose.yml │ │ └── test_data.json └── sharedb │ ├── @types │ └── @teamwork │ │ └── websocket-json-stream.d.ts │ ├── index.ts │ ├── package.json │ ├── src │ └── thothInterface.ts │ └── tsconfig.json ├── pyserver ├── .gitignore ├── envReader.py ├── files │ ├── config │ │ └── .env │ ├── training_data │ │ └── vector_search_data.txt │ └── utils │ │ └── main.html ├── main.py ├── postgres.py ├── requirements.txt ├── server.py ├── utils.py └── vector_search.py ├── refactor-notes.md ├── runner-notes.md ├── scripts ├── application_start.sh ├── application_stop.sh ├── before_install.sh └── seed_dev.sh ├── seeders └── default-seeds.js ├── tsconfig.json └── yarn.lock /.eslintignore: -------------------------------------------------------------------------------- 1 | dist/ 2 | build/ 3 | node_modules/ 4 | test/ 5 | scripts/ 6 | .eslintrc.js 7 | jest.config.js 8 | src/libs 9 | @types -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # MacOS Window Manager 3 | .DS_Store 4 | 5 | # Dependencies 6 | node_modules 7 | build 8 | .DS_Store 9 | .vscode/chrome 10 | 11 | # Generated Styles for AreaPlugin 12 | core/src/plugins/areaPlugin/style.css.d.ts 13 | yarn-error.log 14 | server/google_credentials.json 15 | packages/server/files/ 16 | 17 | # Ignore lockfiles 18 | .idea 19 | 20 | .env.local 21 | .env.*.local 22 | 23 | .dfx -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | 16.10.0 2 | -------------------------------------------------------------------------------- /.prettierrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "trailingComma": "es5", 3 | "tabWidth": 2, 4 | "useTabs": false, 5 | "semi": false, 6 | "singleQuote": true, 7 | "arrowParens": "avoid" 8 | } 9 | -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | // Use IntelliSense to learn about possible attributes. 3 | // Hover to view descriptions of existing attributes. 4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 5 | "version": "0.2.0", 6 | "configurations": [ 7 | { 8 | "type": "pwa-chrome", 9 | "request": "launch", 10 | "name": "Launch Chrome against localhost", 11 | "url": "http://localhost:3003", 12 | "sourceMap": true, 13 | "webRoot": "${workspaceFolder}/client", 14 | "trace": true, 15 | "sourceMapPathOverrides": { 16 | "webpack://thothCore/./*": "${workspaceFolder}/core/*", 17 | "webpack://@thothai/thoth-core/./*": "${workspaceFolder}/core/*", 18 | "webpack://@thothai/thoth-client/./*": "${workspaceFolder}/client/*", 19 | "webpack://@thothai/thoth-client/thothCore/*": "${workspaceFolder}/core/*" 20 | } 21 | } 22 | ] 23 | } 24 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "editor.formatOnSave": true, 3 | "editor.defaultFormatter": "esbenp.prettier-vscode", 4 | "prettier.configPath": "./.prettierrc.json", 5 | "eslint.workingDirectories": ["./client", "./core", "./server"], 6 | "typescript.tsserver.experimental.enableProjectDiagnostics": true, 7 | "cSpell.enabled": false 8 | } 9 | -------------------------------------------------------------------------------- /.yarnrc: -------------------------------------------------------------------------------- 1 | # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. 2 | # yarn lockfile v1 3 | 4 | 5 | yarn-path ".yarn/releases/yarn-1.18.0.cjs" 6 | -------------------------------------------------------------------------------- /CONTRIBUTORS.txt: -------------------------------------------------------------------------------- 1 | This file contains a list of people who have made large contributions 2 | to the public version of Voyage Thoth. 3 | 4 | Original application concept and architecture: 5 | Michael Sharpe 6 | 7 | Stargate Design System designed by: 8 | Preston Gull 9 | 10 | Large code contributions by: 11 | Sean Gillespie 12 | Jakob Grant -------------------------------------------------------------------------------- /appspec.yml: -------------------------------------------------------------------------------- 1 | version: 0.0 2 | os: linux 3 | files: 4 | - source: / 5 | destination: /opt/thoth 6 | file_exists_behavior: OVERWRITE 7 | hooks: 8 | ApplicationStop: 9 | - location: scripts/application_stop.sh 10 | timeout: 300 11 | runas: root 12 | BeforeInstall: 13 | - location: scripts/before_install.sh 14 | timeout: 300 15 | runas: root 16 | ApplicationStart: 17 | - location: scripts/application_start.sh 18 | timeout: 300 19 | runas: root -------------------------------------------------------------------------------- /docs/.gitignore: -------------------------------------------------------------------------------- 1 | # Dependencies 2 | /node_modules 3 | 4 | # Production 5 | /build 6 | 7 | # Generated files 8 | .docusaurus 9 | .cache-loader 10 | 11 | # Misc 12 | .DS_Store 13 | .env.local 14 | .env.development.local 15 | .env.test.local 16 | .env.production.local 17 | 18 | npm-debug.log* 19 | yarn-debug.log* 20 | yarn-error.log* 21 | node_modules 22 | -------------------------------------------------------------------------------- /docs/README.md: -------------------------------------------------------------------------------- 1 | # Website 2 | 3 | This website is built using [Docusaurus 2](https://docusaurus.io/), a modern static website generator. 4 | 5 | ### Installation 6 | 7 | ``` 8 | $ yarn 9 | ``` 10 | 11 | ### Local Development 12 | 13 | ``` 14 | $ yarn start 15 | ``` 16 | 17 | This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server. 18 | 19 | ### Build 20 | 21 | ``` 22 | $ yarn build 23 | ``` 24 | 25 | This command generates static content into the `build` directory and can be served using any static contents hosting service. 26 | 27 | ### Deployment 28 | 29 | Using SSH: 30 | 31 | ``` 32 | $ USE_SSH=true yarn deploy 33 | ``` 34 | 35 | Not using SSH: 36 | 37 | ``` 38 | $ GIT_USER= yarn deploy 39 | ``` 40 | 41 | If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch. 42 | -------------------------------------------------------------------------------- /docs/archive/tutorial-basics/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Tutorial - Basics", 3 | "position": 2 4 | } 5 | -------------------------------------------------------------------------------- /docs/archive/tutorial-basics/congratulations.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 6 3 | --- 4 | 5 | # Congratulations! 6 | 7 | You have just learned the **basics of Docusaurus** and made some changes to the **initial template**. 8 | 9 | Docusaurus has **much more to offer**! 10 | 11 | Have **5 more minutes**? Take a look at **[versioning](../tutorial-extras/manage-docs-versions.md)** and **[i18n](../tutorial-extras/translate-your-site.md)**. 12 | 13 | Anything **unclear** or **buggy** in this tutorial? [Please report it!](https://github.com/facebook/docusaurus/discussions/4610) 14 | 15 | ## What's next? 16 | 17 | - Read the [official documentation](https://docusaurus.io/). 18 | - Add a custom [Design and Layout](https://docusaurus.io/docs/styling-layout) 19 | - Add a [search bar](https://docusaurus.io/docs/search) 20 | - Find inspirations in the [Docusaurus showcase](https://docusaurus.io/showcase) 21 | - Get involved in the [Docusaurus Community](https://docusaurus.io/community/support) 22 | -------------------------------------------------------------------------------- /docs/archive/tutorial-basics/create-a-blog-post.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 3 3 | --- 4 | 5 | # Create a Blog Post 6 | 7 | Docusaurus creates a **page for each blog post**, but also a **blog index page**, a **tag system**, an **RSS** feed... 8 | 9 | ## Create your first Post 10 | 11 | Create a file at `blog/2021-02-28-greetings.md`: 12 | 13 | ```md title="blog/2021-02-28-greetings.md" 14 | --- 15 | slug: greetings 16 | title: Greetings! 17 | authors: 18 | - name: Joel Marcey 19 | title: Co-creator of Docusaurus 1 20 | url: https://github.com/JoelMarcey 21 | image_url: https://github.com/JoelMarcey.png 22 | - name: Sébastien Lorber 23 | title: Docusaurus maintainer 24 | url: https://sebastienlorber.com 25 | image_url: https://github.com/slorber.png 26 | tags: [greetings] 27 | --- 28 | 29 | Congratulations, you have made your first post! 30 | 31 | Feel free to play around and edit this post as much you like. 32 | ``` 33 | 34 | A new blog post is now available at `http://localhost:3000/blog/greetings`. 35 | -------------------------------------------------------------------------------- /docs/archive/tutorial-basics/deploy-your-site.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 5 3 | --- 4 | 5 | # Deploy your site 6 | 7 | Docusaurus is a **static-site-generator** (also called **[Jamstack](https://jamstack.org/)**). 8 | 9 | It builds your site as simple **static HTML, JavaScript and CSS files**. 10 | 11 | ## Build your site 12 | 13 | Build your site **for production**: 14 | 15 | ```bash 16 | npm run build 17 | ``` 18 | 19 | The static files are generated in the `build` folder. 20 | 21 | ## Deploy your site 22 | 23 | Test your production build locally: 24 | 25 | ```bash 26 | npm run serve 27 | ``` 28 | 29 | The `build` folder is now served at `http://localhost:3000/`. 30 | 31 | You can now deploy the `build` folder **almost anywhere** easily, **for free** or very small cost (read the **[Deployment Guide](https://docusaurus.io/docs/deployment)**). 32 | -------------------------------------------------------------------------------- /docs/archive/tutorial-extras/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Tutorial - Extras", 3 | "position": 3 4 | } 5 | -------------------------------------------------------------------------------- /docs/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [require.resolve('@docusaurus/core/lib/babel/preset')], 3 | }; 4 | -------------------------------------------------------------------------------- /docs/blog/2019-05-28-first-blog-post.md: -------------------------------------------------------------------------------- 1 | --- 2 | slug: first-blog-post 3 | title: First Blog Post 4 | authors: 5 | name: Gao Wei 6 | title: Docusaurus Core Team 7 | url: https://github.com/wgao19 8 | image_url: https://github.com/wgao19.png 9 | tags: [hola, docusaurus] 10 | --- 11 | 12 | Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque elementum dignissim ultricies. Fusce rhoncus ipsum tempor eros aliquam consequat. Lorem ipsum dolor sit amet 13 | -------------------------------------------------------------------------------- /docs/blog/2021-08-01-mdx-blog-post.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | slug: mdx-blog-post 3 | title: MDX Blog Post 4 | authors: [slorber] 5 | tags: [docusaurus] 6 | --- 7 | 8 | Blog posts support [Docusaurus Markdown features](https://docusaurus.io/docs/markdown-features), such as [MDX](https://mdxjs.com/). 9 | 10 | :::tip 11 | 12 | Use the power of React to create interactive blog posts. 13 | 14 | ```js 15 | 16 | ``` 17 | 18 | 19 | 20 | ::: 21 | -------------------------------------------------------------------------------- /docs/blog/2021-08-26-welcome/docusaurus-plushie-banner.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/blog/2021-08-26-welcome/docusaurus-plushie-banner.jpeg -------------------------------------------------------------------------------- /docs/blog/2021-08-26-welcome/index.md: -------------------------------------------------------------------------------- 1 | --- 2 | slug: welcome 3 | title: Welcome 4 | authors: [slorber, yangshun] 5 | tags: [facebook, hello, docusaurus] 6 | --- 7 | 8 | [Docusaurus blogging features](https://docusaurus.io/docs/blog) are powered by the [blog plugin](https://docusaurus.io/docs/api/plugins/@docusaurus/plugin-content-blog). 9 | 10 | Simply add Markdown files (or folders) to the `blog` directory. 11 | 12 | Regular blog authors can be added to `authors.yml`. 13 | 14 | The blog post date can be extracted from filenames, such as: 15 | 16 | - `2019-05-30-welcome.md` 17 | - `2019-05-30-welcome/index.md` 18 | 19 | A blog post folder can be convenient to co-locate blog post images: 20 | 21 | ![Docusaurus Plushie](./docusaurus-plushie-banner.jpeg) 22 | 23 | The blog supports tags as well! 24 | 25 | **And if you don't want a blog**: just delete this directory, and use `blog: false` in your Docusaurus config. 26 | -------------------------------------------------------------------------------- /docs/blog/authors.yml: -------------------------------------------------------------------------------- 1 | endi: 2 | name: Endilie Yacop Sucipto 3 | title: Maintainer of Docusaurus 4 | url: https://github.com/endiliey 5 | image_url: https://github.com/endiliey.png 6 | 7 | yangshun: 8 | name: Yangshun Tay 9 | title: Front End Engineer @ Facebook 10 | url: https://github.com/yangshun 11 | image_url: https://github.com/yangshun.png 12 | 13 | slorber: 14 | name: Sébastien Lorber 15 | title: Docusaurus maintainer 16 | url: https://sebastienlorber.com 17 | image_url: https://github.com/slorber.png 18 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/BackPropagation.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Back Propagation 3 | description: This is where you will find information about back propagation. 4 | hide_table_of_contents: false 5 | sidebar_position: 4 6 | --- 7 | 8 | # Back Propagation 9 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/ConceptsOverview.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Concepts Overview 3 | description: Get started with the core concepts of thoth 4 | hide_table_of_contents: false 5 | sidebar_position: 0 6 | --- 7 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/FewShots.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Few Shots 3 | description: This is where you will find information relevant to Few Shots. 4 | hide_table_of_contents: false 5 | sidebar_position: 5 6 | --- 7 | 8 | # Few Shot 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/FlowBasedProgramming.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Flow Based Programming 3 | description: This is where you will find the core concepts reguarding flow based programming. 4 | hide_table_of_contents: false 5 | sidebar_position: 1 6 | --- 7 | 8 | # Flow Based Programming 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/LogicFlow.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Logic Flow 3 | description: This is where you will find information relevant to logical flows. 4 | hide_table_of_contents: false 5 | sidebar_position: 6 6 | --- 7 | 8 | # Logic Flow 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/TriggerControlFlow.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Trigger Control Flow 3 | description: This is where you will find information relevant to the trigger control flow. 4 | hide_table_of_contents: false 5 | sidebar_position: 3 6 | --- 7 | 8 | # Trigger Control Flow 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Core Concepts", 3 | "position": 2 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/core-concepts/nodes.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Nodes 3 | description: This is where you will find information relevant to the Nodes. 4 | hide_table_of_contents: false 5 | sidebar_position: 2 6 | --- 7 | 8 | # Nodes 9 | 10 | # Socket Inputs 11 | 12 | How are you? 13 | 14 | # Socket Outputs 15 | 16 | How are you? 17 | 18 | # Work 19 | 20 | How are you? 21 | -------------------------------------------------------------------------------- /docs/docs/creators/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Creators", 3 | "position": 2 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/creators/apikey/DestroyApiKey.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Destroy API Key 3 | description: This is where you will find information relevant to destroying API key. 4 | hide_table_of_contents: false 5 | sidebar_position: 2 6 | --- 7 | 8 | # Destroying an API key 9 | 10 | If you need to generate a new key for what ever reason, you will go to the API key section under user setttings and then click on API key. You will see your current API key displayed without the key itself. 11 | 12 | ![Current API key](/img/apikey/current-api-key.png) 13 | 14 | Clicking on the Destroy API Key button will delete your current key and then give you the ability to generate a new one. 15 | -------------------------------------------------------------------------------- /docs/docs/creators/apikey/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "API Keys", 3 | "position": 2 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/CallingASpell.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Calling a spell 3 | description: This is where you will find information on how to call a spell. 4 | hide_table_of_contents: false 5 | sidebar_position: 6 6 | --- 7 | 8 | # Calling A Spell 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/ConnectingComponents.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Connecting your first component 3 | description: This is where you will learn how to connect your first component. 4 | hide_table_of_contents: false 5 | sidebar_position: 2 6 | --- 7 | 8 | # Connecting Components 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/CreatorWelcome.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Welcome 3 | description: A welcome to get you started making things with thoth 4 | hide_table_of_contents: false 5 | sidebar_position: 0 6 | --- 7 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/DeployASpell.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Deploy A Spell 3 | description: This is where you will learn how to deploy a spell. 4 | hide_table_of_contents: false 5 | sidebar_position: 5 6 | --- 7 | 8 | # Deploying A Spell 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/FirstFewshot.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Writing your first Few Shot 3 | description: This is where you will learn how to write your first few shot. 4 | hide_table_of_contents: false 5 | sidebar_position: 3 6 | --- 7 | 8 | # First Few Shot 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/MakingASpell.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Making a new Spell 3 | description: This is where you will find information on how to make a new spell. 4 | hide_table_of_contents: false 5 | sidebar_position: 1 6 | --- 7 | 8 | # Making A Spell 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/WorkingWithState.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Working with state 3 | description: This is where you will learn how to work with state. 4 | hide_table_of_contents: false 5 | sidebar_position: 4 6 | --- 7 | 8 | # Working With State 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/gettingStarted/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Getting Started", 3 | "position": 1 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/creators/templates/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Templates", 3 | "position": 3 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/ComponentSelector.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Component Selector 3 | description: This is where you will find information relevant to the component Selector. 4 | hide_table_of_contents: false 5 | sidebar_position: 3 6 | --- 7 | 8 | # Component Selector 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/Console.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Console 3 | description: This is where you will find information relevant to the console. 4 | hide_table_of_contents: false 5 | sidebar_position: 6 6 | --- 7 | 8 | # Console 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/Help.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Help 3 | description: This is where you will find help. 4 | hide_table_of_contents: false 5 | sidebar_position: 7 6 | --- 7 | 8 | # Help 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/Layout.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Layout 3 | description: This is where you will find information relevant to the layout. 4 | hide_table_of_contents: false 5 | sidebar_position: 2 6 | --- 7 | 8 | # Layout 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/Overview.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: UI Overview 3 | description: This is where you will find information relevant to the UI. 4 | hide_table_of_contents: false 5 | sidebar_position: 1 6 | --- 7 | 8 | # UI Overview 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/SpellComposer.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Spell Composer 3 | description: This is where you will find information relevant to the spell composer. 4 | hide_table_of_contents: false 5 | sidebar_position: 2 6 | --- 7 | 8 | # Spell Composer 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/StateManager.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: State Manager 3 | description: This is where you will find information relevant to the state manager. 4 | hide_table_of_contents: false 5 | sidebar_position: 5 6 | --- 7 | 8 | # State Manager 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/TextEditor.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Text Editor 3 | description: This is where you will find information relevant to the text editor. 4 | hide_table_of_contents: false 5 | sidebar_position: 4 6 | --- 7 | 8 | # Text Editor 9 | 10 | How are you? 11 | -------------------------------------------------------------------------------- /docs/docs/creators/userInterface/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "User Interface", 3 | "position": 2 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/developers/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Developers", 3 | "position": 4 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/Architecture.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Architecture 3 | description: This is where you will find information relevant to the architecture of Thoth. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Architecture 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/Contexts.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Contexts 3 | description: This is where you will find information relevant to the various Contexts used. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Contexts 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/InspectorControls.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Inspector Controls 3 | description: This is where you will find information relevant to the inspector controls. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Inspector Controls 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/Layouts.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Layouts 3 | description: This is where you will find information relevant to the layouts of Thoth. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Layouts 8 | 9 | # Windows 10 | 11 | # Layout json 12 | 13 | # Generate a new layout 14 | 15 | How are you? 16 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/OperationalTransforms.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Operational Transforms 3 | description: This is where you will find information relevant to json0 operational transforms. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Operational Transforms 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/Plugins.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Plugins 3 | description: This is where you will find information relevant to the plugin system. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Plugins 8 | 9 | # Debugger plugin 10 | 11 | # Inspector plugin 12 | 13 | # Socket generator 14 | 15 | # task generator 16 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/ReteEditor.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Rete Editor 3 | description: This is where you will find information relevant to the Rete Editor. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Rete Editor 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/State.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: State 3 | description: This is where you will find information relevant to state management. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # State 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/ThothInterface.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Thoth Interface 3 | description: This is where you will find information relevant to the Thoth Interface. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Thoth Interface 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/WorkspacesAndTabs.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Workspaces and Tabs 3 | description: This is where you will find information relevant to the Workspaces and tabs in Thoth. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Workspaces 8 | 9 | # Tabs 10 | 11 | How are you? 12 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Architecture Overview", 3 | "position": 2 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/developers/architecture overview/pubsub.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: PubSub 3 | description: This is where you will find information relevant to the pubsub layer of Thoth. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # PubSub 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/getting started/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Getting Started", 3 | "position": 1 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/developers/getting started/installingThoth.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Installing Thoth 3 | description: This is where you will find information relevant to the Stargate Design System. 4 | hide_table_of_contents: false 5 | sidebar_position: 1 6 | --- 7 | -------------------------------------------------------------------------------- /docs/docs/developers/getting started/intro.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Developing Thoth 3 | description: Start yoiur journey into helping us develop thoth 4 | hide_table_of_contents: false 5 | sidebar_position: 1 6 | --- 7 | -------------------------------------------------------------------------------- /docs/docs/developers/packageOverview/StargateDesignSystem.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Stargate Design system 3 | description: This is where you will find information relevant to the Stargate Design System. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # Stargate Design System 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/packageOverview/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Package Overview", 3 | "position": 3 4 | } 5 | -------------------------------------------------------------------------------- /docs/docs/developers/packageOverview/thoth-client-core.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Thoth Client Core 3 | description: This is where you will find information relevant to the thoth-client-core package. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # thoth-client-core 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/packageOverview/thoth-client.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Thoth Client 3 | description: This is where you will find information relevant to the thoth-client package. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # thoth-client 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/packageOverview/thoth-core.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Thoth Core 3 | description: This is where you will find information relevant to the thoth-core package. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # thoth-core 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/packageOverview/thoth-server-core.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Thoth Server Core 3 | description: This is where you will find information relevant to the thoth-server-core package. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # thoth-server-core 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/docs/developers/packageOverview/thoth-server.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Thoth Server 3 | description: This is where you will find information relevant to the thoth-server package. 4 | hide_table_of_contents: false 5 | --- 6 | 7 | # thoth-server 8 | 9 | How are you? 10 | -------------------------------------------------------------------------------- /docs/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@thothai/docs", 3 | "version": "0.0.0", 4 | "private": true, 5 | "scripts": { 6 | "docusaurus": "docusaurus", 7 | "start": "docusaurus start --port 3008", 8 | "build": "docusaurus build", 9 | "swizzle": "docusaurus swizzle", 10 | "deploy": "docusaurus deploy", 11 | "clear": "docusaurus clear", 12 | "serve": "docusaurus serve", 13 | "write-translations": "docusaurus write-translations", 14 | "write-heading-ids": "docusaurus write-heading-ids" 15 | }, 16 | "dependencies": { 17 | "@docusaurus/core": "2.0.0-beta.18", 18 | "@docusaurus/preset-classic": "2.0.0-beta.18", 19 | "@mdx-js/react": "^1.6.22", 20 | "clsx": "^1.1.1", 21 | "prism-react-renderer": "^1.3.1", 22 | "react": "^17.0.2", 23 | "react-dom": "^17.0.2" 24 | }, 25 | "browserslist": { 26 | "production": [ 27 | ">0.5%", 28 | "not dead", 29 | "not op_mini all" 30 | ], 31 | "development": [ 32 | "last 1 chrome version", 33 | "last 1 firefox version", 34 | "last 1 safari version" 35 | ] 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /docs/sidebars.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Creating a sidebar enables you to: 3 | - create an ordered group of docs 4 | - render a sidebar for each doc of that group 5 | - provide next/previous navigation 6 | 7 | The sidebars can be generated from the filesystem, or explicitly defined here. 8 | 9 | Create as many sidebars as you want. 10 | */ 11 | 12 | // @ts-check 13 | 14 | /** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */ 15 | const sidebars = { 16 | // By default, Docusaurus generates a sidebar from the docs folder structure 17 | tutorialSidebar: [{ type: 'autogenerated', dirName: '.' }], 18 | 19 | // But you can create a sidebar manually 20 | /* 21 | tutorialSidebar: [ 22 | { 23 | type: 'category', 24 | label: 'Tutorial', 25 | items: ['hello'], 26 | }, 27 | ], 28 | */ 29 | } 30 | 31 | module.exports = sidebars 32 | -------------------------------------------------------------------------------- /docs/src/components/HomepageFeatures/ThothDemo.js: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import styles from './styles.module.css' 3 | 4 | export default function ThothDemo() { 5 | return ( 6 |
7 |
8 |
9 | 10 |
11 |
12 |
13 | ) 14 | } 15 | -------------------------------------------------------------------------------- /docs/src/components/HomepageFeatures/styles.module.css: -------------------------------------------------------------------------------- 1 | .features { 2 | display: flex; 3 | align-items: center; 4 | padding: 2rem 0; 5 | width: 100%; 6 | } 7 | 8 | .featureSvg { 9 | height: 200px; 10 | width: 200px; 11 | } 12 | -------------------------------------------------------------------------------- /docs/src/pages/index.module.css: -------------------------------------------------------------------------------- 1 | /** 2 | * CSS files with the .module.css suffix will be treated as CSS modules 3 | * and scoped locally. 4 | */ 5 | 6 | .heroBanner { 7 | padding: 4rem 0; 8 | text-align: center; 9 | position: relative; 10 | overflow: hidden; 11 | background: '#424242'; 12 | } 13 | 14 | @media screen and (max-width: 996px) { 15 | .heroBanner { 16 | padding: 2rem; 17 | } 18 | } 19 | 20 | .buttons { 21 | display: flex; 22 | align-items: center; 23 | justify-content: center; 24 | } 25 | 26 | .githubButtons { 27 | display: flex; 28 | left: 1%; 29 | position: relative; 30 | } 31 | -------------------------------------------------------------------------------- /docs/src/pages/markdown-page.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Markdown page example 3 | --- 4 | 5 | # Markdown page example 6 | 7 | You don't need React to write simple standalone pages. 8 | -------------------------------------------------------------------------------- /docs/static/.nojekyll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/.nojekyll -------------------------------------------------------------------------------- /docs/static/img/Thoth-Screen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/Thoth-Screen.png -------------------------------------------------------------------------------- /docs/static/img/apikey/api-key-copied.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/api-key-copied.png -------------------------------------------------------------------------------- /docs/static/img/apikey/api-key-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/api-key-page.png -------------------------------------------------------------------------------- /docs/static/img/apikey/created-api-key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/created-api-key.png -------------------------------------------------------------------------------- /docs/static/img/apikey/current-api-key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/current-api-key.png -------------------------------------------------------------------------------- /docs/static/img/apikey/generate-api-key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/generate-api-key.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-add-to-header.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-add-to-header.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-apikey-input.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-apikey-input.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-authorization-tab.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-authorization-tab.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-body-input.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-body-input.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-body-tab.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-body-tab.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-key.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-new-tab.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-new-tab.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-overview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-overview.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-request-type.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-request-type.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-send.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-send.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-url-input.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-url-input.png -------------------------------------------------------------------------------- /docs/static/img/apikey/postman-value.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/postman-value.png -------------------------------------------------------------------------------- /docs/static/img/apikey/settings-api-key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/settings-api-key.png -------------------------------------------------------------------------------- /docs/static/img/apikey/settings-menu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/settings-menu.png -------------------------------------------------------------------------------- /docs/static/img/apikey/user-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/apikey/user-icon.png -------------------------------------------------------------------------------- /docs/static/img/docusaurus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/docusaurus.png -------------------------------------------------------------------------------- /docs/static/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/favicon.ico -------------------------------------------------------------------------------- /docs/static/img/thoth-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/thoth-logo.png -------------------------------------------------------------------------------- /docs/static/img/tutorial/docsVersionDropdown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/tutorial/docsVersionDropdown.png -------------------------------------------------------------------------------- /docs/static/img/tutorial/localeDropdown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/docs/static/img/tutorial/localeDropdown.png -------------------------------------------------------------------------------- /jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "module": "commonjs", 4 | "target": "ES2021", 5 | "jsx": "preserve" 6 | }, 7 | "exclude": ["node_modules", "**/node_modules/*"] 8 | } 9 | -------------------------------------------------------------------------------- /lerna.json: -------------------------------------------------------------------------------- 1 | { 2 | "packages": [ 3 | "packages/*" 4 | ], 5 | "npmClient": "yarn", 6 | "useWorkspaces": true, 7 | "version": "0.1.3" 8 | } 9 | -------------------------------------------------------------------------------- /netlify/plugins/conditional-canary/index.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | onPreBuild: ({ netlifyConfig, utils: { git } }) => { 3 | const coreChanges = git.fileMatch('core/**/*') 4 | const coreChanged = coreChanges.edited.length !== 0 5 | const installCanary = 6 | 'cd client && yarn add @thothai/thoth-core@canary && cd ..' 7 | netlifyConfig.build.command = coreChanged 8 | ? `${installCanary} && ${netlifyConfig.build.command}` 9 | : netlifyConfig.build.command 10 | }, 11 | } 12 | -------------------------------------------------------------------------------- /netlify/plugins/conditional-canary/manifest.yml: -------------------------------------------------------------------------------- 1 | name: conditional-canary 2 | -------------------------------------------------------------------------------- /netlify/plugins/staging-canary/index.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | onPreBuild: ({ netlifyConfig, utils: { git } }) => { 3 | netlifyConfig.build.command = `cd client && yarn add @thothai/thoth-core@canary && cd .. && ${netlifyConfig.build.command}` 4 | }, 5 | } 6 | -------------------------------------------------------------------------------- /netlify/plugins/staging-canary/manifest.yml: -------------------------------------------------------------------------------- 1 | name: staging-canary 2 | -------------------------------------------------------------------------------- /ot-notes.md: -------------------------------------------------------------------------------- 1 | Important operations 2 | 3 | - delete node 4 | - add node 5 | - modify node 6 | - node translated 7 | - connection added 8 | - connection removed 9 | - data updated 10 | - socket added/removed 11 | -------------------------------------------------------------------------------- /packages/client/.env.example: -------------------------------------------------------------------------------- 1 | EXTEND_ESLINT = true 2 | 3 | # This prod site root assumes the netlify build context $URL is available, replace for other hosts 4 | REACT_APP_SITE_ROOT_URL_PROD=$URL 5 | REACT_APP_SITE_ROOT_URL=http://localhost:3003 6 | REACT_APP_LAPI_ROOT_URL=http://localhost:8000 7 | REACT_APP_LAPI_ROOT_URL_PROD=https://api.latitude.io 8 | REACT_APP_SITE_STAGING=https://62264f21c3a9860ad1e5bdd3--optimistic-turing-def916.netlify.app/ 9 | 10 | # Oauth Client Id 11 | REACT_APP_OAUTH_CLIENT_ID=a6b51c87-7565-42ab-a4b0-38a07f3b6c56 -------------------------------------------------------------------------------- /packages/client/.eslintignore: -------------------------------------------------------------------------------- 1 | dist/ 2 | build/ 3 | node_modules/ 4 | test/ 5 | scripts/ 6 | .eslintrc.js 7 | jest.config.js 8 | src/libs 9 | @types -------------------------------------------------------------------------------- /packages/client/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | extends: ['../.eslintrc.js', 'react-app'], 3 | parserOptions: { 4 | project: './tsconfig.json', 5 | ecmaFeatures: { 6 | jsx: true, 7 | }, 8 | ecmaVersion: 2018, 9 | sourceType: 'module', 10 | }, 11 | rules: { 12 | 'react-hooks/exhaustive-deps': 0, 13 | }, 14 | } 15 | -------------------------------------------------------------------------------- /packages/client/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | build 3 | .DS_Store 4 | dist 5 | .env.local 6 | .env.*.local 7 | .dfx -------------------------------------------------------------------------------- /packages/client/.npmrc: -------------------------------------------------------------------------------- 1 | # Add Github npm package registry, so we can install private npm packages 2 | @latitudegames:registry=https://npm.pkg.github.com/ 3 | //npm.pkg.github.com/:_authToken=${NPM_TOKEN} 4 | 5 | -------------------------------------------------------------------------------- /packages/client/TODO.md: -------------------------------------------------------------------------------- 1 | TODO 2 | 3 | X fix saving spell to DB after loading an NFT that exists 4 | X add refresh button for refreshing tokens 5 | X trigger reload of NFTs after clicking the mint button 6 | 7 | - centralize all NFT stuff into context 8 | - move management functionality to its own modal 9 | -------------------------------------------------------------------------------- /packages/client/canister_ids.json: -------------------------------------------------------------------------------- 1 | { 2 | "assets": { 3 | "ic": "f4zho-laaaa-aaaam-qaquq-cai" 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /packages/client/dfx.json: -------------------------------------------------------------------------------- 1 | { 2 | "canisters": { 3 | "assets": { 4 | "frontend": { 5 | "entrypoint": "build/index.html" 6 | }, 7 | "source": ["build/"], 8 | "type": "assets" 9 | } 10 | }, 11 | "defaults": { 12 | "build": { 13 | "packtool": "" 14 | } 15 | }, 16 | "dfx": "0.9.3", 17 | "networks": { 18 | "local": { 19 | "bind": "127.0.0.1:8000", 20 | "type": "ephemeral" 21 | }, 22 | "ic": { 23 | "providers": ["https://mainnet.dfinity.network"], 24 | "type": "persistent" 25 | } 26 | }, 27 | "version": 1 28 | } 29 | -------------------------------------------------------------------------------- /packages/client/public/_redirects: -------------------------------------------------------------------------------- 1 | /* /index.html 200 -------------------------------------------------------------------------------- /packages/client/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/public/favicon.ico -------------------------------------------------------------------------------- /packages/client/public/logo192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/public/logo192.png -------------------------------------------------------------------------------- /packages/client/public/logo512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/public/logo512.png -------------------------------------------------------------------------------- /packages/client/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "React App", 3 | "name": "Create React App Sample", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | }, 10 | { 11 | "src": "logo192.png", 12 | "type": "image/png", 13 | "sizes": "192x192" 14 | }, 15 | { 16 | "src": "logo512.png", 17 | "type": "image/png", 18 | "sizes": "512x512" 19 | } 20 | ], 21 | "start_url": ".", 22 | "display": "standalone", 23 | "theme_color": "#000000", 24 | "background_color": "#ffffff" 25 | } 26 | -------------------------------------------------------------------------------- /packages/client/public/robots.txt: -------------------------------------------------------------------------------- 1 | # https://www.robotstxt.org/robotstxt.html 2 | User-agent: * 3 | Disallow: 4 | -------------------------------------------------------------------------------- /packages/client/scripts/engine.ts: -------------------------------------------------------------------------------- 1 | import thothCore from '@thothai/thoth-core/dist/server' 2 | 3 | const { 4 | components: { moduleInput, moduleOutput, tenseTransformer }, 5 | } = thothCore 6 | 7 | export const components = [ 8 | // new ActionTypeComponent(), 9 | // new Alert(), 10 | // new BooleanGate(), 11 | // new Code(), 12 | // new DifficultyDetectorComponent(), 13 | // new EnkiTask(), 14 | // new EntityDetector(), 15 | // new ForEach(), 16 | // new Generator(), 17 | // new InputComponent(), 18 | // new ItemTypeComponent(), 19 | // new JoinListComponent(), 20 | // new ModuleComponent(), 21 | moduleInput(), 22 | moduleOutput(), 23 | // new PlaytestPrint(), 24 | // new PlaytestInput(), 25 | // new RunInputComponent(), 26 | // new SafetyVerifier(), 27 | // new StateWrite(), 28 | // new StateRead(), 29 | // new StringProcessor(), 30 | // new SwitchGate(), 31 | tenseTransformer(), 32 | // new TimeDetectorComponent(), 33 | ] 34 | -------------------------------------------------------------------------------- /packages/client/scripts/module.ts: -------------------------------------------------------------------------------- 1 | export class Module { 2 | inputs: object; 3 | outputs: object; 4 | constructor() { 5 | this.inputs = {}; 6 | this.outputs = {}; 7 | } 8 | 9 | read(inputs) { 10 | this.inputs = inputs; 11 | } 12 | 13 | write(outputs) { 14 | Object.keys(this.outputs).forEach((key) => { 15 | outputs[key] = this.outputs[key]; 16 | }); 17 | } 18 | 19 | getInput(key) { 20 | return this.inputs[key]; 21 | } 22 | 23 | setOutput(key, value) { 24 | this.outputs[key] = value; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /packages/client/scripts/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "commonjs", 3 | "dependencies": { 4 | "ts-node": "^10.8.1", 5 | "typescript": "^4.6.4" 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /packages/client/scripts/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../tsconfig.json", 3 | "compilerOptions": { 4 | "isolatedModules": false, 5 | "module": "CommonJS" 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /packages/client/src/App.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/components/Accordion/accordion-overrides.css: -------------------------------------------------------------------------------- 1 | .MuiAccordionSummary-content { 2 | margin: 0 !important; 3 | } 4 | .MuiAccordionSummary-root { 5 | min-height: var(--c4) !important; 6 | } 7 | .MuiAccordionDetails-root { 8 | padding: var(--small) !important; 9 | padding-left: var(--c4) !important; 10 | padding-right: var(--small) !important; 11 | padding-top: var(--medium) !important; 12 | } 13 | .MuiCollapse-wrapperInner { 14 | border-top: 1px solid var(--dark-2) !important; 15 | } 16 | .MuiAccordion-root.Mui-expanded { 17 | /* margin-top: var(--extraSmall) !important; */ 18 | /* margin-bottom: var(--extraSmall) !important; */ 19 | } 20 | 21 | .MuiAccordionSummary-expandIcon { 22 | margin-left: var(--extraSmall) !important; 23 | transform: rotate(-90deg) !important; 24 | } 25 | .MuiAccordion-root.Mui-expanded .MuiAccordionSummary-expandIcon { 26 | transform: rotate(0deg) !important; 27 | } -------------------------------------------------------------------------------- /packages/client/src/components/Accordion/accordion-overrides.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/components/Accordion/accordion.module.css: -------------------------------------------------------------------------------- 1 | .accordion { 2 | background-color: var(--dark-1); 3 | box-sizing: border-box; 4 | position: relative; 5 | border-bottom: 1px solid var(--dark-1); 6 | } -------------------------------------------------------------------------------- /packages/client/src/components/Accordion/accordion.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'accordion': string; 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/components/Button/button.module.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/components/Button/button.module.css -------------------------------------------------------------------------------- /packages/client/src/components/Chip/Chip.tsx: -------------------------------------------------------------------------------- 1 | import Icon from '../Icon/Icon' 2 | import css from './chip.module.css' 3 | 4 | const Chip = ({ 5 | label, 6 | onClick, 7 | noEvents, 8 | }: { 9 | label: string 10 | onClick?: () => {} 11 | noEvents?: boolean 12 | }) => { 13 | return ( 14 |
18 | {label} 19 | {!noEvents && } 20 |
21 | ) 22 | } 23 | 24 | export default Chip 25 | -------------------------------------------------------------------------------- /packages/client/src/components/Chip/chip.module.css: -------------------------------------------------------------------------------- 1 | .chip { 2 | width: 100%; 3 | box-sizing: border-box; 4 | color: #fff; 5 | border-radius: 4px; 6 | cursor: default; 7 | background-color: var(--dark-3); 8 | border: 1px solid var(--dark-4); 9 | padding: 9px 16px; 10 | padding-left: var(--small); 11 | padding-right: var(--small); 12 | font-size: 11px; 13 | height: var(--c4); 14 | display: flex; 15 | align-items: center; 16 | justify-content: space-between; 17 | } 18 | .chip:hover { 19 | filter: brightness(1.1); 20 | } 21 | .chip.no-events { 22 | pointer-events: none; 23 | background-color: var(--dark-2); 24 | box-shadow: none; 25 | border-color: var(--dark-3); 26 | color: var(--dark-4); 27 | font-family: "IBM Plex Mono"; 28 | text-transform: uppercase; 29 | } -------------------------------------------------------------------------------- /packages/client/src/components/Chip/chip.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'chip': string; 5 | 'no-events': string; 6 | } 7 | export const cssExports: CssExports; 8 | export default cssExports; 9 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/Icon.tsx: -------------------------------------------------------------------------------- 1 | import css from './icon.module.css' 2 | 3 | export const componentCategories = { 4 | 'AI/ML': 'play-print', 5 | 'I/O': 'water', 6 | Logic: 'switch', 7 | State: 'state', 8 | Module: 'cup', 9 | Core: 'ankh', 10 | } 11 | 12 | export const dataControlCategories = { 13 | 'Data Inputs': 'properties', 14 | 'Data Outputs': 'properties', 15 | Fewshot: 'fewshot', 16 | Stop: 'stop-sign', 17 | Temperature: 'temperature', 18 | 'Max Tokens': 'moon', 19 | } 20 | 21 | const Icon = ({ name = 'warn', size = 16, style = {}, onClick = () => {} }) => { 22 | return ( 23 |
28 | ) 29 | } 30 | 31 | export default Icon 32 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/add.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/close.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/dangerTrash.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/fewshot.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/folder.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/minus.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/node-lock.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/pause.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/play.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/stop.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/trash.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/client/src/components/Icon/warn.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Input/Input.tsx: -------------------------------------------------------------------------------- 1 | const Input = ({ value, onChange = e => {}, style = {}, ...props }) => { 2 | return ( 3 | 10 | ) 11 | } 12 | 13 | export default Input 14 | -------------------------------------------------------------------------------- /packages/client/src/components/Input/input.module.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/components/Input/input.module.css -------------------------------------------------------------------------------- /packages/client/src/components/LoadingScreen/LoadingScreen.jsx: -------------------------------------------------------------------------------- 1 | import ankh from './ankh.gif' 2 | 3 | const LoadingScreen = () => ( 4 |
11 |
20 | {'loading'} 29 |

Please wait...

30 |
31 |
32 | ) 33 | 34 | export default LoadingScreen 35 | -------------------------------------------------------------------------------- /packages/client/src/components/LoadingScreen/ankh.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/components/LoadingScreen/ankh.gif -------------------------------------------------------------------------------- /packages/client/src/components/MenuBar/menuBar.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'folder-arrow': string; 5 | 'list-item': string; 6 | 'menu-bar': string; 7 | 'menu-bar-item': string; 8 | 'menu-panel': string; 9 | 'preference-active': string; 10 | 'preference-notActive': string; 11 | 'thoth-logo': string; 12 | } 13 | export const cssExports: CssExports; 14 | export default cssExports; 15 | -------------------------------------------------------------------------------- /packages/client/src/components/MenuBar/thoth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/components/MenuBar/thoth.png -------------------------------------------------------------------------------- /packages/client/src/components/Mint/dabStuff.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/components/Modal/modal.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'modal': string; 5 | 'modal-action-strip': string; 6 | 'modal-bg': string; 7 | 'modal-main-div': string; 8 | 'modal-panel': string; 9 | 'modal-panel-content': string; 10 | 'modal-title': string; 11 | 'vertical': string; 12 | } 13 | export const cssExports: CssExports; 14 | export default cssExports; 15 | -------------------------------------------------------------------------------- /packages/client/src/components/Modals/AgentModal.tsx: -------------------------------------------------------------------------------- 1 | import { useState } from 'react' 2 | import Modal from '../Modal/Modal' 3 | 4 | const AgentModal = ({ content, onClose, options: _options }) => { 5 | const [message, setMessage] = useState('') 6 | const options = [ 7 | { 8 | label: 'Create Agent', 9 | className: 'primary', 10 | onClick: () => { 11 | onClose({ name: message }) 12 | }, 13 | }, 14 | ] 15 | const updateNotes = e => { 16 | console.log("message is ", e.target.value) 17 | setMessage(e.target.value) 18 | } 19 | 20 | return ( 21 | 22 |
23 |

Agent Name

24 | 25 |
26 | ) 27 | } 28 | 29 | export default AgentModal 30 | -------------------------------------------------------------------------------- /packages/client/src/components/Modals/DeleteModal.tsx: -------------------------------------------------------------------------------- 1 | import Modal from '../Modal/Modal' 2 | import css from './modalForms.module.css' 3 | import { useForm } from 'react-hook-form' 4 | 5 | const DeleteModal = ({ closeModal, handledelete, id }) => { 6 | const { 7 | handleSubmit, 8 | // formState: { errors }, 9 | } = useForm() 10 | const onSubmit = handleSubmit(async () => { 11 | handledelete(id) 12 | 13 | closeModal() 14 | }) 15 | const options = [ 16 | { 17 | className: `${css['delete-btn']}`, 18 | label: 'Delete', 19 | onClick: onSubmit, 20 | }, 21 | ] 22 | 23 | return ( 24 | 30 | ) 31 | } 32 | 33 | export default DeleteModal 34 | -------------------------------------------------------------------------------- /packages/client/src/components/Modals/ExampleModal.jsx: -------------------------------------------------------------------------------- 1 | import { useModal } from '../../contexts/ModalProvider' 2 | import Modal from '../Modal/Modal' 3 | 4 | const ExampleModal = ({ content }) => { 5 | const { closeModal } = useModal() 6 | const options = [ 7 | { label: 'Oki doki', className: 'primary', onClick: closeModal }, 8 | ] 9 | return ( 10 | 11 |

{content}

12 |
13 | ) 14 | } 15 | 16 | export default ExampleModal 17 | -------------------------------------------------------------------------------- /packages/client/src/components/Modals/InfoModal.tsx: -------------------------------------------------------------------------------- 1 | import Modal from '../../components/Modal/Modal' 2 | 3 | interface InfoModal { 4 | title: string 5 | content: string 6 | checkbox?: { 7 | onClick: () => {} 8 | label: string 9 | } 10 | } 11 | 12 | const InfoModal = ({ title, content, checkbox }: InfoModal) => { 13 | return ( 14 | 15 |

{content}

16 | {checkbox && ( 17 |
23 | 24 | 29 |
30 | )} 31 |
32 | ) 33 | } 34 | 35 | export default InfoModal 36 | -------------------------------------------------------------------------------- /packages/client/src/components/Modals/SearchCorpus/ContentObjEditModal.tsx: -------------------------------------------------------------------------------- 1 | import ContentObject from '@/workspaces/spells/windows/ContentObject'; 2 | import Modal from '../../Modal/Modal' 3 | 4 | const ContentObjEditModal = ({ contents, getContentObjects }) => { 5 | 6 | return ( 7 | 8 |
9 | {contents.length > 0 ? 10 | contents.map(content => ( 11 | 12 | ) 13 | ) : ( 14 |

No content objects exists

15 | )} 16 | 17 |
18 | ); 19 | } 20 | 21 | export default ContentObjEditModal; -------------------------------------------------------------------------------- /packages/client/src/components/Modals/loginModal.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'error-message': string; 5 | 'input': string; 6 | 'input-container': string; 7 | 'login-container': string; 8 | } 9 | export const cssExports: CssExports; 10 | export default cssExports; 11 | -------------------------------------------------------------------------------- /packages/client/src/components/Modals/modalForms.module.css: -------------------------------------------------------------------------------- 1 | .input { 2 | flex: 1; 3 | width: 100%; 4 | margin-top: var(--c1); 5 | color: white; 6 | } 7 | .select { 8 | color: white; 9 | } 10 | 11 | .input-container { 12 | margin-top: var(--c3); 13 | } 14 | 15 | .login-container { 16 | display: flex; 17 | flex-direction: column; 18 | margin-bottom: var(--c1); 19 | } 20 | 21 | .error-message { 22 | margin-top: var(--c1); 23 | color: var(--red); 24 | text-align: center; 25 | } 26 | 27 | .delete-btn { 28 | background: rgb(255, 55, 55); 29 | color: white; 30 | } 31 | .delete-modal { 32 | width: 20rem; 33 | } 34 | -------------------------------------------------------------------------------- /packages/client/src/components/Modals/modalForms.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'delete-btn': string; 5 | 'delete-modal': string; 6 | 'error-message': string; 7 | 'input': string; 8 | 'input-container': string; 9 | 'login-container': string; 10 | 'select': string; 11 | } 12 | export const cssExports: CssExports; 13 | export default cssExports; 14 | -------------------------------------------------------------------------------- /packages/client/src/components/Node/Node.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'bottom-container': string; 5 | 'connection-container': string; 6 | 'connections-container': string; 7 | 'control': string; 8 | 'deprecated-overlay': string; 9 | 'error': string; 10 | 'input': string; 11 | 'node': string; 12 | 'node-depricated': string; 13 | 'node-id': string; 14 | 'node-locked': string; 15 | 'node-title': string; 16 | 'nodeGenesis': string; 17 | 'out': string; 18 | 'output': string; 19 | 'selected': string; 20 | 'success': string; 21 | } 22 | export const cssExports: CssExports; 23 | export default cssExports; 24 | -------------------------------------------------------------------------------- /packages/client/src/components/Panel/Panel.tsx: -------------------------------------------------------------------------------- 1 | import css from './panel.module.css' 2 | 3 | const Panel = ({ 4 | style = {}, 5 | unpadded = false, 6 | shade = false, 7 | shadow = false, 8 | bacgkroundImageURL = '', 9 | hover = false, 10 | roundness = '', 11 | className = '', 12 | flexRow = false, 13 | flexColumn = false, 14 | gap = '', 15 | ...props 16 | }) => { 17 | return ( 18 |
34 | {props.children} 35 |
36 | ) 37 | } 38 | 39 | export default Panel 40 | -------------------------------------------------------------------------------- /packages/client/src/components/Panel/panel.module.css: -------------------------------------------------------------------------------- 1 | .panel { 2 | text-align: left; 3 | display: inline-block; 4 | color: #fff; 5 | padding: var(--small); 6 | background-color: var(--dark-2); 7 | border-radius: var(--extraSmall); 8 | box-sizing: border-box; 9 | background-position: center; 10 | background-size: cover; 11 | overflow: hidden; 12 | } 13 | .panel.unpadded { 14 | padding: 0; 15 | } 16 | .panel.square { 17 | border-radius: 0; 18 | } 19 | .panel.round { 20 | border-radius: 4px; 21 | } 22 | .panel.rounder { 23 | border-radius: var(--extraSmall); 24 | } 25 | .panel.roundest { 26 | border-radius: var(--small); 27 | } 28 | .panel.shadow { 29 | box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.2); 30 | } 31 | -------------------------------------------------------------------------------- /packages/client/src/components/Panel/panel.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'panel': string; 5 | 'round': string; 6 | 'rounder': string; 7 | 'roundest': string; 8 | 'shadow': string; 9 | 'square': string; 10 | 'unpadded': string; 11 | } 12 | export const cssExports: CssExports; 13 | export default cssExports; 14 | -------------------------------------------------------------------------------- /packages/client/src/components/PlugWallet/plugWallet.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/components/RequireAuth/RequireAuth.tsx: -------------------------------------------------------------------------------- 1 | import { useLatitude } from '@/config' 2 | import { Outlet } from 'react-router-dom' 3 | import { useAuth } from '../../contexts/AuthProvider' 4 | 5 | const defaultGroups = ['internal', 'thoth', 'creator-tester'] 6 | 7 | const RequireAuth = (props: Record) => { 8 | if (!useLatitude) return 9 | const { user, loginRedirect } = useAuth() 10 | const groups = props?.access 11 | ? [...props?.access, ...defaultGroups] 12 | : defaultGroups 13 | 14 | const authorized = 15 | user && 16 | !user.groups.includes('public') && 17 | user.groups.some(g => groups.includes(g)) 18 | 19 | if (!authorized && user?.id) 20 | window.location.href = 'https://voyage.latitude.io' 21 | else if (!authorized) loginRedirect() 22 | 23 | return 24 | } 25 | 26 | export default RequireAuth 27 | -------------------------------------------------------------------------------- /packages/client/src/components/Select/select.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'dropdown-indicator': string; 5 | 'group-header': string; 6 | 'select-dropdown-container': string; 7 | } 8 | export const cssExports: CssExports; 9 | export default cssExports; 10 | -------------------------------------------------------------------------------- /packages/client/src/components/Switch/Switch.tsx: -------------------------------------------------------------------------------- 1 | import Switch from '@mui/material/Switch' 2 | import FormControlLabel from '@mui/material/FormControlLabel' 3 | 4 | const SwitchComponent = ({ label: _label, checked, onChange }) => { 5 | const label = { inputProps: { 'aria-label': _label } } 6 | return ( 7 | } 10 | /> 11 | ) 12 | } 13 | 14 | export default SwitchComponent 15 | -------------------------------------------------------------------------------- /packages/client/src/components/TabBar/CreateTab.tsx: -------------------------------------------------------------------------------- 1 | import css from './tabBar.module.css' 2 | import { VscAdd } from 'react-icons/vsc' 3 | import { useNavigate } from 'react-router-dom' 4 | 5 | const CreateTab = () => { 6 | const navigate = useNavigate() 7 | 8 | const onCreate = () => { 9 | navigate('/home/create-new') 10 | } 11 | 12 | return ( 13 |
17 | 18 | 19 | 20 |
21 | ) 22 | } 23 | 24 | export default CreateTab 25 | -------------------------------------------------------------------------------- /packages/client/src/components/TabBar/tabBar.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'active': string; 5 | 'create-spell-tab': string; 6 | 'inactive': string; 7 | 'tabbar-section': string; 8 | 'tabbar-tab': string; 9 | 'tabbar-user': string; 10 | 'th-tabbar': string; 11 | 'thoth-logo': string; 12 | } 13 | export const cssExports: CssExports; 14 | export default cssExports; 15 | -------------------------------------------------------------------------------- /packages/client/src/components/TabLayout/TabLayout.jsx: -------------------------------------------------------------------------------- 1 | import css from './TabLayout.module.css' 2 | 3 | const TabLayout = ({ children }) => { 4 | return ( 5 | <> 6 |
7 |
{children}
8 |
9 | 10 | ) 11 | } 12 | 13 | export default TabLayout 14 | -------------------------------------------------------------------------------- /packages/client/src/components/TabLayout/TabLayout.module.css: -------------------------------------------------------------------------------- 1 | .view-container { 2 | padding: var(--c1); 3 | height: 100%; 4 | background-color: var(--dark-1); 5 | border: 1px solid var(--dark-2); 6 | border-radius: 4px; 7 | } 8 | -------------------------------------------------------------------------------- /packages/client/src/components/TabLayout/TabLayout.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'view-container': string; 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/components/ThothPage/ThothPageWrapper.tsx: -------------------------------------------------------------------------------- 1 | import ModalProvider from '../../contexts/ModalProvider' 2 | import TabBar from '../TabBar/TabBar' 3 | import css from './pagewrapper.module.css' 4 | import { useLocation } from 'react-router-dom' 5 | 6 | const ThothPageWrapper = ({ tabs, activeTab, ...props }) => { 7 | const location = useLocation() 8 | return ( 9 | 10 |
11 | {location.pathname.slice(1, 6) !== 'admin' && ( 12 | 13 | )} 14 | {props.children} 15 |
16 |
17 | ) 18 | } 19 | export default ThothPageWrapper 20 | -------------------------------------------------------------------------------- /packages/client/src/components/ThothPage/pagewrapper.module.css: -------------------------------------------------------------------------------- 1 | .wrapper { 2 | display: flex; 3 | flex-direction: column; 4 | margin: var(--c1); 5 | margin-top: 6px; 6 | height: calc(100% - var(--c2)); 7 | } 8 | -------------------------------------------------------------------------------- /packages/client/src/components/ThothPage/pagewrapper.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'wrapper': string; 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/components/Toolbar/Toolbar.tsx: -------------------------------------------------------------------------------- 1 | import css from './toolbar.module.css' 2 | 3 | const Toolbar = ({ ...props }) => { 4 | return ( 5 |
6 |
{props.toolbar}
7 |
{props.options}
8 |
9 | ) 10 | } 11 | 12 | export default Toolbar 13 | -------------------------------------------------------------------------------- /packages/client/src/components/Toolbar/toolbar.module.css: -------------------------------------------------------------------------------- 1 | .th-toolbar { 2 | flex: 1; 3 | display: inline-block; 4 | padding: var(--extraSmall); 5 | background-color: var(--dark-2); 6 | /* border-bottom: 1px solid var(--dark-2); */ 7 | width: 100%; 8 | display: flex; 9 | align-items: center; 10 | box-sizing: border-box; 11 | box-shadow: 0 4px 5px rgba(0, 0, 0, 0.5); 12 | z-index: 8; 13 | min-height: var(--c6); 14 | } 15 | .toolbar-section { 16 | display: flex; 17 | flex: 1; 18 | } 19 | .toolbar-section:last-child { 20 | justify-content: flex-end; 21 | } 22 | .toolbar-section button { 23 | margin-left: var(--extraSmall); 24 | } 25 | -------------------------------------------------------------------------------- /packages/client/src/components/Window/WindowToolbar.tsx: -------------------------------------------------------------------------------- 1 | import css from './window.module.css' 2 | 3 | const WindowToolbar = props => { 4 | return
{props.children}
5 | } 6 | 7 | export default WindowToolbar 8 | -------------------------------------------------------------------------------- /packages/client/src/components/Window/window.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'bordered': string; 5 | 'darkened': string; 6 | 'darker': string; 7 | 'grid': string; 8 | 'lock-bar': string; 9 | 'unpadded': string; 10 | 'window': string; 11 | 'window-layout': string; 12 | 'window-toolbar': string; 13 | } 14 | export const cssExports: CssExports; 15 | export default cssExports; 16 | -------------------------------------------------------------------------------- /packages/client/src/components/z. Don't use/TextInput/TextInput.tsx: -------------------------------------------------------------------------------- 1 | import { useState, useEffect } from 'react' 2 | 3 | import css from './textinput.module.css' 4 | 5 | const TextInput = ({ props }) => { 6 | const [value, setValue] = useState('') 7 | 8 | useEffect(() => { 9 | setValue(props?.value) 10 | }, [props]) 11 | 12 | const onChange = e => { 13 | setValue(e.target?.value) 14 | } 15 | 16 | return ( 17 | 23 | ) 24 | } 25 | 26 | export default TextInput 27 | -------------------------------------------------------------------------------- /packages/client/src/components/z. Don't use/TextInput/textinput.module.css: -------------------------------------------------------------------------------- 1 | input.text-input { 2 | box-sizing: border-box; 3 | padding: 4px; /* not using a var here to optically correct for base + cap of typeface */ 4 | background-color: var(--dark-2); 5 | padding-left: var(--small); 6 | padding-right: var(--small); 7 | color: #fff; 8 | border-radius: 4px; 9 | cursor: default; 10 | background-color: var(--dark-1); 11 | border: 1px solid var(--dark-3); 12 | box-shadow: inset 0px 5px 5px rgba(0,0,0,0.1); 13 | font-family: 'IBM Plex Mono', monospace !important; 14 | } -------------------------------------------------------------------------------- /packages/client/src/config.d.ts: -------------------------------------------------------------------------------- 1 | export declare const latitudeApiRootUrl: string; 2 | export declare const thothApiRootUrl: string; 3 | export declare const oAuthClientId: string | undefined; 4 | export declare const appRootUrl: string | undefined; 5 | export declare const useLatitude: boolean; 6 | -------------------------------------------------------------------------------- /packages/client/src/config.ts: -------------------------------------------------------------------------------- 1 | export const latitudeApiRootUrl = 2 | process.env.NODE_ENV === 'production' 3 | ? (process.env.REACT_APP_LAPI_ROOT_URL_PROD as string) 4 | : (process.env.REACT_APP_LAPI_ROOT_URL as string) 5 | 6 | export const thothApiRootUrl = 7 | process.env.NODE_ENV === 'production' 8 | ? (process.env.REACT_APP_API_ROOT_URL_PROD as string) 9 | : (process.env.REACT_APP_API_ROOT_URL as string) 10 | 11 | export const oAuthClientId = process.env.REACT_APP_OAUTH_CLIENT_ID 12 | 13 | export const appRootUrl = 14 | process.env.NODE_ENV === 'production' 15 | ? process.env.REACT_APP_SITE_ROOT_URL_PROD 16 | : process.env.REACT_APP_SITE_ROOT_URL 17 | 18 | export const useLatitude = process.env.REACT_APP_USE_LATITUDE === 'true'; 19 | // coercing this into a boolean 20 | export const sharedb = process.env.REACT_APP_SHAREDB === 'true' 21 | export const websockets = process.env.REACT_APP_WEBSOCKETS === 'true' 22 | export const feathers = process.env.REACT_APP_FEATHERS === 'true' 23 | export const feathersUrl = 'http://localhost:3030' 24 | export const websocketUrl = 'ws://localhost:8080' 25 | -------------------------------------------------------------------------------- /packages/client/src/contexts/ModalProvider.jsx: -------------------------------------------------------------------------------- 1 | import React, { useState } from 'react' 2 | 3 | import { getModals } from '../components/Modals' 4 | 5 | const Context = React.createContext({ 6 | activeModal: '', 7 | // eslint-disable-next-line @typescript-eslint/no-unused-vars 8 | openModal: options => { }, 9 | closeModal: () => { }, 10 | }) 11 | 12 | export const useModal = () => React.useContext(Context) 13 | 14 | const ModalContext = ({ children }) => { 15 | const modalList = getModals() 16 | const [activeModal, setActiveModal] = useState('') 17 | 18 | const openModal = modalOptions => { 19 | setActiveModal({ ...modalOptions, closeModal }) 20 | } 21 | 22 | const closeModal = () => { 23 | setActiveModal('') 24 | } 25 | const Modal = modalList[activeModal.modal] 26 | 27 | return ( 28 | 34 | {activeModal && } 35 | {children} 36 | 37 | ) 38 | } 39 | 40 | export default ModalContext 41 | -------------------------------------------------------------------------------- /packages/client/src/design-globals/design-globals.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/global.d.ts: -------------------------------------------------------------------------------- 1 | // We need to tell TypeScript that when we write "import styles from './styles.scss' we mean to load a module (to look for a './styles.scss.d.ts'). 2 | declare module '*.css' 3 | declare module '*.module.css' 4 | declare module '*.jpg' 5 | declare module '*.png' { 6 | const value: any 7 | export default value 8 | } 9 | 10 | declare global { 11 | interface Window { 12 | getLayout: any 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /packages/client/src/grid.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/grid.png -------------------------------------------------------------------------------- /packages/client/src/helpers/Expire.ts: -------------------------------------------------------------------------------- 1 | import { getSessionId } from '../contexts/AuthProvider' 2 | import { latitudeApiRootUrl } from '../config' 3 | 4 | export const callExpire = async () => { 5 | const sessionId = await getSessionId() 6 | const endpoint = `${latitudeApiRootUrl}/user/expire` 7 | await fetch(endpoint, { 8 | method: 'GET', 9 | headers: { 10 | 'Content-Type': 'application/json', 11 | Authorization: `session ${sessionId}`, 12 | }, 13 | }).catch(err => { 14 | // throw new Error(err) 15 | // eslint-disable-next-line no-console 16 | console.log(err) 17 | }) 18 | } 19 | -------------------------------------------------------------------------------- /packages/client/src/hooks/useQuery.ts: -------------------------------------------------------------------------------- 1 | import { useLocation } from "react-router-dom"; 2 | 3 | export const useQuery = () => { 4 | return new URLSearchParams(useLocation().search); 5 | }; 6 | -------------------------------------------------------------------------------- /packages/client/src/react-app-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | -------------------------------------------------------------------------------- /packages/client/src/reportWebVitals.js: -------------------------------------------------------------------------------- 1 | const reportWebVitals = onPerfEntry => { 2 | if (onPerfEntry && onPerfEntry instanceof Function) { 3 | import('web-vitals').then(({ getCLS, getFID, getFCP, getLCP, getTTFB }) => { 4 | getCLS(onPerfEntry) 5 | getFID(onPerfEntry) 6 | getFCP(onPerfEntry) 7 | getLCP(onPerfEntry) 8 | getTTFB(onPerfEntry) 9 | }) 10 | } 11 | } 12 | 13 | export default reportWebVitals 14 | -------------------------------------------------------------------------------- /packages/client/src/screens/Admin/Layout/index.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'selected': string; 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/screens/Admin/common/Variable/column.ts: -------------------------------------------------------------------------------- 1 | export const columnClientSetting = [ 2 | { 3 | id: 'client', 4 | name: 'Client', 5 | }, 6 | { 7 | id: 'name', 8 | name: 'Name', 9 | }, 10 | { 11 | id: 'type', 12 | name: 'Type', 13 | }, 14 | { 15 | id: 'default_value', 16 | name: 'Deafult Value', 17 | }, 18 | ] 19 | 20 | export const columnConfig = [ 21 | { 22 | id: 'key', 23 | name: 'Key', 24 | }, 25 | { 26 | id: 'value', 27 | name: 'Value', 28 | }, 29 | ] 30 | 31 | export const columnScope = [ 32 | { 33 | id: 'tables', 34 | name: 'Tables', 35 | }, 36 | { 37 | id: 'full_table_size', 38 | name: 'Full table size', 39 | }, 40 | { 41 | id: 'table_size', 42 | name: 'Table size', 43 | }, 44 | { 45 | id: 'record_count', 46 | name: 'Record count ', 47 | }, 48 | ] 49 | -------------------------------------------------------------------------------- /packages/client/src/screens/Admin/routes/index.tsx: -------------------------------------------------------------------------------- 1 | import { Routes, Route } from 'react-router-dom' 2 | import AdminLayout from '../Layout' 3 | import Scope from '../component/Scope' 4 | import ClientSetting from '../component/clientSetting' 5 | import Config from '../component/Config' 6 | 7 | export default function AdminRoute() { 8 | return ( 9 | 10 | }> 11 | } /> 12 | } /> 13 | } /> 14 | } /> 15 | 16 | 17 | ) 18 | } 19 | -------------------------------------------------------------------------------- /packages/client/src/screens/Calendar/DayLabels.tsx: -------------------------------------------------------------------------------- 1 | const DayLabels = () => { 2 | const DAYS_SHORT = ['MON', 'TUE', 'WED', 'THU', 'FRI', 'SAT', 'SUN'] 3 | return ( 4 | <> 5 | {DAYS_SHORT.map((dayLabel, index) => ( 6 |
7 | {dayLabel} 8 |
9 | ))} 10 | 11 | ) 12 | } 13 | 14 | export default DayLabels 15 | -------------------------------------------------------------------------------- /packages/client/src/screens/Calendar/calendar.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 5 | } 6 | export const cssExports: CssExports; 7 | export default cssExports; 8 | -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/components/FileInput.jsx: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import { VscDebugBreakpointConditionalUnverified } from 'react-icons/vsc' 3 | 4 | import Icon from '../../../components/Icon/Icon' 5 | 6 | const FileInput = ({ loadFile }) => { 7 | const hiddenFileInput = React.useRef(null) 8 | 9 | const handleClick = () => { 10 | hiddenFileInput.current.click() 11 | } 12 | 13 | const handleChange = event => { 14 | const fileUploaded = event.target.files[0] 15 | loadFile(fileUploaded) 16 | } 17 | return ( 18 | <> 19 | 23 | 29 | 30 | ) 31 | } 32 | 33 | export default FileInput 34 | -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/components/TemplatePanel.jsx: -------------------------------------------------------------------------------- 1 | import Panel from '../../../components/Panel/Panel' 2 | import css from '../homeScreen.module.css' 3 | 4 | const TemplatePanel = ({ template, setSelectedTemplate, selectedTemplate }) => { 5 | const isSelected = 6 | selectedTemplate?.label && selectedTemplate.label === template.label 7 | return ( 8 |
{ 13 | setSelectedTemplate(template) 14 | }} 15 | > 16 | 26 |

{template.label}

27 |
28 | ) 29 | } 30 | 31 | export default TemplatePanel 32 | -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/components/VideoInput.jsx: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | 3 | import Icon from '../../../components/Icon/Icon' 4 | 5 | const VideoInput = ({ loadFile }) => { 6 | const hiddenFileInput = React.useRef(null) 7 | 8 | const handleClick = () => { 9 | hiddenFileInput.current.click() 10 | } 11 | 12 | const handleChange = event => { 13 | const fileUploaded = event.target.files[0] 14 | loadFile(fileUploaded) 15 | } 16 | return ( 17 | <> 18 | 22 | 29 | 30 | ) 31 | } 32 | 33 | export default VideoInput 34 | -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/screens/HomeScreen/empty.png -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/enki.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/screens/HomeScreen/enki.png -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/homeScreen.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'button-row': string; 5 | 'center-container': string; 6 | 'error-message': string; 7 | 'input': string; 8 | 'label': string; 9 | 'open-project-container': string; 10 | 'overlay': string; 11 | 'project-row': string; 12 | 'selected': string; 13 | 'spell-details': string; 14 | 'template-container': string; 15 | 'template-panel': string; 16 | 'version-banner': string; 17 | } 18 | export const cssExports: CssExports; 19 | export default cssExports; 20 | -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/lang.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/screens/HomeScreen/lang.png -------------------------------------------------------------------------------- /packages/client/src/screens/HomeScreen/version-banner-0.0.0beta.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AtlasFoundation/Thoth/f15db64136363cfff5bbae69229ce6b504e18c2e/packages/client/src/screens/HomeScreen/version-banner-0.0.0beta.jpg -------------------------------------------------------------------------------- /packages/client/src/screens/Thoth/thoth.module.css.d.ts: -------------------------------------------------------------------------------- 1 | // This file is automatically generated. 2 | // Please do not change this file! 3 | interface CssExports { 4 | 'active': string; 5 | 'bottom-container': string; 6 | 'code-editor': string; 7 | 'form-text-area': string; 8 | 'node-bottom-container': string; 9 | 'node-grid': string; 10 | 'node-grid-item': string; 11 | 'node-title': string; 12 | 'playtest-input': string; 13 | 'playtest-output': string; 14 | 'tab': string; 15 | 'tab-page': string; 16 | 'tabs': string; 17 | 'th-sidepanel': string; 18 | } 19 | export const cssExports: CssExports; 20 | export default cssExports; 21 | -------------------------------------------------------------------------------- /packages/client/src/speechUtils.d.ts: -------------------------------------------------------------------------------- 1 | export declare class singleton { 2 | static instance: speechUtils; 3 | static getInstance(): speechUtils; 4 | } 5 | declare class speechUtils { 6 | bufferSize: number; 7 | AudioContext: any; 8 | context: any; 9 | processor: any; 10 | input: any; 11 | globalStream: any; 12 | finalWord: boolean; 13 | removeLastSentence: boolean; 14 | streamStreaming: boolean; 15 | constraints: { 16 | audio: boolean; 17 | video: boolean; 18 | }; 19 | socket: import("socket.io-client").Socket; 20 | constructor(); 21 | initRecording: (newMessageCallback: Function) => void; 22 | microphoneProcess: (e: any) => void; 23 | stopRecording: () => void; 24 | downsampleBuffer: (buffer: any, sampleRate: any, outSampleRate: any) => any; 25 | } 26 | export default singleton; 27 | -------------------------------------------------------------------------------- /packages/client/src/state/admin/clientS/clientService.ts: -------------------------------------------------------------------------------- 1 | import axios from 'axios' 2 | class ClientService { 3 | getAll(currentPage = 1, page = 10) { 4 | return axios.get( 5 | `${process.env.REACT_APP_API_ROOT_URL}/setting/client?per_page=${page}&page=${currentPage}` 6 | ) 7 | } 8 | getOne(search) { 9 | return axios.get( 10 | `${process.env.REACT_APP_API_ROOT_URL}/setting/client?search=${search}&field=client` 11 | ) 12 | } 13 | get(id) { 14 | return axios.get( 15 | `${process.env.REACT_APP_API_ROOT_URL}/setting/client?id=${id}` 16 | ) 17 | } 18 | create(data) { 19 | return axios.post( 20 | `${process.env.REACT_APP_API_ROOT_URL}/setting/client`, 21 | data 22 | ) 23 | } 24 | update(id, data) { 25 | return axios.patch( 26 | `${process.env.REACT_APP_API_ROOT_URL}/setting/client?id=${id}`, 27 | data 28 | ) 29 | } 30 | delete(id) { 31 | return axios.delete( 32 | `${process.env.REACT_APP_API_ROOT_URL}/setting/client?id=${id}` 33 | ) 34 | } 35 | } 36 | export default new ClientService() 37 | -------------------------------------------------------------------------------- /packages/client/src/state/admin/scope/scopeService.ts: -------------------------------------------------------------------------------- 1 | import axios from 'axios' 2 | class ScopeService { 3 | getAll(currentPage = 1, page = 10) { 4 | return axios.get( 5 | `${process.env.REACT_APP_API_ROOT_URL}/setting/scope?per_page=${page}&page=${currentPage}` 6 | ) 7 | } 8 | getOne(search) { 9 | return axios.get( 10 | `${process.env.REACT_APP_API_ROOT_URL}/setting/scope?search=${search}&field=tables` 11 | ) 12 | } 13 | get(id) { 14 | return axios.get( 15 | `${process.env.REACT_APP_API_ROOT_URL}/setting/scope?id=${id}` 16 | ) 17 | } 18 | create(data) { 19 | return axios.post( 20 | `${process.env.REACT_APP_API_ROOT_URL}/setting/scope`, 21 | data 22 | ) 23 | } 24 | update(id, data) { 25 | return axios.patch( 26 | `${process.env.REACT_APP_API_ROOT_URL}/setting/scope?id=${id}`, 27 | data 28 | ) 29 | } 30 | delete(id) { 31 | return axios.delete( 32 | `${process.env.REACT_APP_API_ROOT_URL}/setting/scope?id=${id}` 33 | ) 34 | } 35 | } 36 | export default new ScopeService() 37 | -------------------------------------------------------------------------------- /packages/client/src/state/api/api.ts: -------------------------------------------------------------------------------- 1 | import { createApi, fetchBaseQuery } from '@reduxjs/toolkit/query/react' 2 | import { getAuthHeader } from '../../contexts/AuthProvider' 3 | import { thothApiRootUrl } from '../../config' 4 | // initialize an empty api service that we'll inject endpoints into later as needed 5 | export const rootApi = createApi({ 6 | reducerPath: 'api', 7 | baseQuery: fetchBaseQuery({ 8 | baseUrl: thothApiRootUrl, 9 | prepareHeaders: async headers => { 10 | const authHeader = await getAuthHeader() 11 | if (authHeader?.Authorization) 12 | headers.set('authorization', authHeader['Authorization']) 13 | return headers 14 | }, 15 | }), 16 | tagTypes: ['Spell', 'Spells', 'Version'], 17 | endpoints: () => ({}), 18 | }) 19 | 20 | console.log("rootApi is") 21 | console.log(rootApi) -------------------------------------------------------------------------------- /packages/client/src/state/api/visualGenerationsApi.ts: -------------------------------------------------------------------------------- 1 | import { ImageCacheResponse } from '@thothai/thoth-core/types' 2 | import { rootApi } from './api' 3 | 4 | export const visualGenerationsApi = rootApi.injectEndpoints({ 5 | endpoints: builder => ({ 6 | fetchFromImageCache: builder.mutation< 7 | ImageCacheResponse, 8 | { caption: string; cacheTag?: string; topK?: number } 9 | >({ 10 | query: searchOptions => ({ 11 | url: '/image/cache/lookup', 12 | method: 'POST', 13 | body: { 14 | ...searchOptions, 15 | }, 16 | }), 17 | }), 18 | }), 19 | }) 20 | 21 | export const { useFetchFromImageCacheMutation } = visualGenerationsApi 22 | -------------------------------------------------------------------------------- /packages/client/src/state/hooks.ts: -------------------------------------------------------------------------------- 1 | import { TypedUseSelectorHook, useDispatch, useSelector } from 'react-redux' 2 | import type { RootState, AppDispatch } from './store' 3 | 4 | // Use throughout your app instead of plain `useDispatch` and `useSelector` 5 | export const useAppDispatch = () => useDispatch() 6 | export const useAppSelector: TypedUseSelectorHook = useSelector 7 | -------------------------------------------------------------------------------- /packages/client/src/state/preferences.ts: -------------------------------------------------------------------------------- 1 | import { createSlice } from '@reduxjs/toolkit' 2 | 3 | export interface Preference { 4 | autoSave: boolean 5 | doNotShowUnlockWarning: boolean 6 | } 7 | 8 | export const preferenceSlice = createSlice({ 9 | name: 'preferences', 10 | initialState: { 11 | autoSave: true, 12 | doNotShowUnlockWarning: false, 13 | }, 14 | reducers: { 15 | toggleAutoSave: state => { 16 | const newState = state.autoSave === true ? false : true 17 | state.autoSave = newState 18 | }, 19 | toggleDoNotShowUnlockWarning: state => { 20 | const newState = state.doNotShowUnlockWarning === true ? false : true 21 | state.doNotShowUnlockWarning = newState 22 | }, 23 | }, 24 | }) 25 | 26 | // actions 27 | export const { toggleAutoSave, toggleDoNotShowUnlockWarning } = 28 | preferenceSlice.actions 29 | 30 | export default preferenceSlice.reducer 31 | -------------------------------------------------------------------------------- /packages/client/src/state/reducers.ts: -------------------------------------------------------------------------------- 1 | import { combineReducers } from 'redux' 2 | 3 | import { spellApi } from './api/spells' 4 | import tabReducer from './tabs' 5 | import configreducer from './admin/config/configState' 6 | import scopeSlice from './admin/scope/scopeState' 7 | import clientSlice from './admin/clientS/clientState' 8 | import preferencesReducer from './preferences' 9 | 10 | const reducers = combineReducers({ 11 | tabs: tabReducer, 12 | preferences: preferencesReducer, 13 | [spellApi.reducerPath]: spellApi.reducer, 14 | config: configreducer, 15 | scope: scopeSlice, 16 | client: clientSlice, 17 | }) 18 | 19 | export default reducers 20 | -------------------------------------------------------------------------------- /packages/client/src/types.ts: -------------------------------------------------------------------------------- 1 | export type ModelsType = { 2 | models: { 3 | modules: { 4 | updateOrCreate: Function 5 | getModule: Function 6 | getModules: Function 7 | updateModule: Function 8 | newModule: Function 9 | findOneModule: Function 10 | } 11 | 12 | spells: { 13 | getSpell: Function 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /packages/client/src/utils/AsyncStorage.ts: -------------------------------------------------------------------------------- 1 | export const getItem = (key: string) => { 2 | const value = window.localStorage.getItem(key) 3 | 4 | try { 5 | if (value === 'undefined' || !value) { 6 | return null 7 | } 8 | const parsedValue = JSON.parse(value) 9 | return parsedValue 10 | } catch { 11 | return value 12 | } 13 | } 14 | 15 | export const setItem = (key: string, value: string) => { 16 | return window.localStorage.setItem(key, value) 17 | } 18 | 19 | export const removeItem = (item: string) => { 20 | return window.localStorage.removeItem(item) 21 | } 22 | 23 | export const clearStorage = () => { 24 | window.localStorage.clear() 25 | } 26 | -------------------------------------------------------------------------------- /packages/client/src/utils/debounce.js: -------------------------------------------------------------------------------- 1 | /* eslint-disable no-invalid-this */ 2 | export function debounceLeading(func, timeout = 300) { 3 | let timer 4 | return (...args) => { 5 | if (!timer) { 6 | func.apply(this, args) 7 | } 8 | clearTimeout(timer) 9 | timer = setTimeout(() => { 10 | timer = undefined 11 | }, timeout) 12 | } 13 | } 14 | 15 | export function debounce(func, timeout = 300) { 16 | let timer 17 | return (...args) => { 18 | clearTimeout(timer) 19 | timer = setTimeout(() => { 20 | func.apply(this, args) 21 | }, timeout) 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /packages/client/src/utils/huggingfaceHelper.js: -------------------------------------------------------------------------------- 1 | import axios from 'axios' 2 | 3 | export const invokeInference = async (model, data) => { 4 | const API_TOKEN = process.env.REACT_APP_HUGGINGFACE_API_TOKEN 5 | 6 | try { 7 | const resp = await axios.post( 8 | `https://api-inference.huggingface.co/models/${model}`, 9 | data, 10 | { 11 | headers: { 12 | 'Content-Type': 'application/json', 13 | Authorization: `Bearer ${API_TOKEN}`, 14 | }, 15 | } 16 | ) 17 | const result = await resp.data 18 | return result 19 | } catch (error) { 20 | console.error(error) 21 | return { error: JSON.stringify(error) } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /packages/client/src/utils/json0.ts: -------------------------------------------------------------------------------- 1 | import jsonDiff from 'json0-ot-diff' 2 | import diffMatchPatch from 'diff-match-patch' 3 | 4 | export const diff = (obj1, obj2) => jsonDiff(obj1, obj2, diffMatchPatch) 5 | -------------------------------------------------------------------------------- /packages/client/src/utils/uuid.ts: -------------------------------------------------------------------------------- 1 | export const uuidv4 = () => { 2 | return "10000000-1000-4000-8000-100000000000".replace( 3 | /[018]/g, 4 | (c: string) => { 5 | const d = parseInt(c); 6 | return ( 7 | d ^ 8 | (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (d / 4))) 9 | ).toString(16); 10 | } 11 | ); 12 | }; 13 | -------------------------------------------------------------------------------- /packages/client/src/wdyr.ts: -------------------------------------------------------------------------------- 1 | /// 2 | import React from 'react' 3 | import whyDidYouRender from '@welldone-software/why-did-you-render' 4 | 5 | if (process.env.NODE_ENV === 'development') { 6 | console.log('running WDYR!') 7 | whyDidYouRender(React, { 8 | trackAllPureComponents: false, 9 | }) 10 | } 11 | -------------------------------------------------------------------------------- /packages/client/src/workspaces/spells/DataControls/CodeControl.jsx: -------------------------------------------------------------------------------- 1 | import { useLayout } from '../../contexts/LayoutProvider' 2 | 3 | const CodeControl = () => { 4 | const { createOrFocus, windowTypes } = useLayout() 5 | 6 | const onClick = () => { 7 | createOrFocus(windowTypes.TEXT_EDITOR, 'Text Editor') 8 | } 9 | 10 | return 11 | } 12 | 13 | export default CodeControl 14 | -------------------------------------------------------------------------------- /packages/client/src/workspaces/spells/DataControls/DropdownSelect.tsx: -------------------------------------------------------------------------------- 1 | import Select from '../../../components/Select/Select' 2 | 3 | const DropdownSelect = ({ control, updateData, initialValue }) => { 4 | const { dataKey, data } = control 5 | 6 | const { values, defaultValue } = data 7 | 8 | const options = values.map(value => ({ 9 | value: value, 10 | label: value, 11 | })) 12 | 13 | const value = initialValue?.length > 0 ? initialValue : defaultValue 14 | 15 | const defaultVal = { value, label: value } 16 | 17 | const onChange = async ({ value }) => { 18 | update(value) 19 | } 20 | 21 | const update = update => { 22 | updateData({ [dataKey]: update }) 23 | } 24 | 25 | if (!defaultVal) return 26 | return ( 27 |
28 |