diff --git a/.dockerignore b/.dockerignore index 0599ab59..c532e524 100644 --- a/.dockerignore +++ b/.dockerignore @@ -2,5 +2,5 @@ node_modules dist bin .venv -.nous/ +.sophia/ diff --git a/.gitignore b/.gitignore index fd39b074..b93c1fb9 100644 --- a/.gitignore +++ b/.gitignore @@ -15,7 +15,7 @@ temp/ .ignore .cache .venv/ -.nous/ +.sophia/ src/cli/*-in src/cli/*-out tg/ diff --git a/Dockerfile b/Dockerfile index de9d1c82..07d7faf4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,10 +11,10 @@ RUN curl -sL https://deb.nodesource.com/setup_20.x -o nodesource_setup.sh RUN chmod +x ./nodesource_setup.sh && ./nodesource_setup.sh RUN apt install -y nodejs -ENV user=nous -ENV homedir=/home/nous/ +ENV user=sophia +ENV homedir=/home/sophia/ -RUN useradd --create-home -g users nous +RUN useradd --create-home -g users sophia WORKDIR $homedir RUN mkdir ".husky" @@ -27,7 +27,7 @@ COPY . . USER $user -RUN mkdir .nous +RUN mkdir .sophia # Generate the function schemas RUN npm run functionSchemas @@ -35,4 +35,3 @@ ENV NODE_ENV=production ENV PORT=8080 EXPOSE 8080 CMD [ "npm", "run", "start" ] - diff --git a/Dockerfile.dev b/Dockerfile.dev index 0b642ec7..fedde9f1 100644 --- a/Dockerfile.dev +++ b/Dockerfile.dev @@ -13,9 +13,9 @@ RUN npm install -g pm2 RUN pip install aider-chat -ENV user=nous -ENV homedir=/home/nous/ -RUN useradd --create-home -g users nous +ENV user=sophia +ENV homedir=/home/sophia/ +RUN useradd --create-home -g users sophia WORKDIR $homedir RUN mkdir ".husky" diff --git a/README.md b/README.md index d2ed0242..cfffaa75 100644 --- a/README.md +++ b/README.md @@ -1,24 +1,24 @@

- nous logo + nous logo

The open-source TypeScript platform for autonomous AI agents and LLM based workflows

-Nous (Greek: νοῦς) is a term from classical philosophy often associated with intellect or intelligence, represents the human mind's capacity to comprehend truth and reality. +The Ancient Greek word sophía (σοφία) is the abstract noun of σοφός (sophós), which variously translates to "clever, skillful, intelligent, wise" ## Documentation site -[Home](https://nous.trafficguard.ai/) | [Setup](https://nous.trafficguard.ai/setup/) | [Observability](https://nous.trafficguard.ai/observability/) | [Function calling](https://nous.trafficguard.ai/functions/) | -[Autonomous AI Agent](https://nous.trafficguard.ai/xml-agent/) | [AI Software Engineer](https://nous.trafficguard.ai/software-engineer/) | [AI Code reviews](https://nous.trafficguard.ai/code-review/) | -[Tools/Integrations](https://nous.trafficguard.ai/integrations/) | [Roadmap](https://nous.trafficguard.ai/roadmap/) +[Home](https://sophia.dev/) | [Setup](https://sophia.dev/setup/) | [Observability](https://sophia.dev/observability/) | [Function calling](https://sophia.dev/functions/) | +[Autonomous AI Agent](https://sophia.dev/xml-agent/) | [AI Software Engineer](https://sophia.dev/software-engineer/) | [AI Code reviews](https://sophia.dev/code-review/) | +[Tools/Integrations](https://sophia.dev/integrations/) | [Roadmap](https://sophia.dev/roadmap/) --- -[The Nous Story](#the-nous-story) | [Features](#features) | [UI Examples](#ui-examples) | [Code examples](#code-examples) | [Contributing](#contributing) +[The Sophia Story](#the-sophia-story) | [Features](#features) | [UI Examples](#ui-examples) | [Code examples](#code-examples) | [Contributing](#contributing) -## The Nous Story +## The Sophia Story -Nous started from a simple goal: to harness AI's potential to enhance real-world productivity, born in DevOps and Platform Engineering space. We envisioned a tool that could: +Sophia started from a simple goal: to harness AI's potential to enhance real-world productivity, born in DevOps and Platform Engineering space. We envisioned a tool that could: - Automate various processes and support requests, and triage build failures. - Review code for compliance with standards and best practices. @@ -30,7 +30,7 @@ Our SaaS on GCP comprises projects developed in TypeScript, Python, GoogleSQL, P With open source projects typically Python/GitHub focused, and the vendor AI tools being focused in their silos, we saw a need for TypeScript based tooling which can work across our entire tech stack, and understand the overall architecture. -Through its evolution we've designed nous as a flexible platform for the TypeScript community to expand and support the use cases and integrations of your choice. +Through its evolution we've designed sophia as a flexible platform for the TypeScript community to expand and support the use cases and integrations of your choice. Our design choice of Firestore for the initial database implementation, with Cloud Run, provides a scale-to-zero solution with zero-cost using the free tier. With the intention to support uses cases such as your own custom personal assistant, always available via mobile. @@ -82,7 +82,7 @@ Key features include: ### New Agent -![New Agent UI](https://public.trafficguard.ai/nous/start.png) +![New Agent UI](https://public.trafficguard.ai/sophia/start.png) ### Sample trace @@ -106,11 +106,11 @@ Key features include: ## Code Examples -### Nous vs LangChain +### Sophia vs LangChain -Nous doesn't use LangChain, for [many reasons](https://www.octomind.dev/blog/why-we-no-longer-use-langchain-for-building-our-ai-agents) that [you](https://www.google.com/search?q=langchain+site%3Anews.ycombinator.com) can [read online](https://www.google.com/search?q=langchain+sucks+site%3Areddit.com) +Sophia doesn't use LangChain, for [many reasons](https://www.octomind.dev/blog/why-we-no-longer-use-langchain-for-building-our-ai-agents) that [you](https://www.google.com/search?q=langchain+site%3Anews.ycombinator.com) can [read online](https://www.google.com/search?q=langchain+sucks+site%3Areddit.com) -Let's compare the LangChain document example for Multiple Chains to the equivalent Nous implementation. +Let's compare the LangChain document example for Multiple Chains to the equivalent Sophia implementation. #### LangChain ```typescript @@ -148,7 +148,7 @@ const result = await combinedChain.invoke({ console.log(result); ``` -#### Nous +#### Sophia ```typescript import { llms } from '#agent/context' import { anthropicLLMs } from '#llms/anthropic' @@ -164,7 +164,7 @@ runAgentWorkflow({ llms: anthropicLLMs() }, async () => { }); ``` -The Nous code also has the advantage of static typing with the prompt arguments, enabling you to refactor with ease. +The Sophia code also has the advantage of static typing with the prompt arguments, enabling you to refactor with ease. Using simple control flow allows easy debugging with breakpoints/logging. To run a fully autonomous agent: @@ -178,9 +178,6 @@ startAgent({ }); ``` -The Nous code also has the advantage of static typing with the prompt arguments, enabling you to refactor with ease. -Using simple control flow allows easy debugging with breakpoints/logging. - ### Automated LLM function schemas LLM function calling schemas are automatically generated by having the `@func` decorator on class methods. diff --git a/docker-compose.yml b/docker-compose.yml index 8370c4c3..9de159b1 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,7 +1,7 @@ # docker compose up --build services: node: - container_name: nous-dev + container_name: sophia-dev restart: always ports: - 4200:4200 @@ -10,11 +10,11 @@ services: context: ./ dockerfile: Dockerfile.dev volumes: - - ~/.config/gcloud:/home/nous/.config/gcloud # Comment out if not using Google Cloud - - .:/home/nous + - ~/.config/gcloud:/home/sophia/.config/gcloud # Comment out if not using Google Cloud + - .:/home/sophia # Install node_modules into the container for cross-platform compatability - - /home/nous/node_modules - - /home/nous/frontend/node_modules + - /home/sophia/node_modules + - /home/sophia/frontend/node_modules # environment: # GIT_DISCOVERY_ACROSS_FILESYSTEM: 1 # - var=value diff --git a/docs/CODE_REVIEW.md b/docs/CODE_REVIEW.md index 4422b699..6979bdaa 100644 --- a/docs/CODE_REVIEW.md +++ b/docs/CODE_REVIEW.md @@ -1,6 +1,6 @@ # Code Review -Nous has the ability to review merge requests on GitLab with configured code review guidelines. +Sophia has the ability to review merge requests on GitLab with configured code review guidelines. Some situations where you may want to use LLMs for reviewing code styles are: - When a linting rule isn't yet available. @@ -75,5 +75,5 @@ Webhooks can be configured at the project or group level, so if you have multipl that you wanted to be reviewed, then you will need to configure a webhook for each one. Follow the [GitLab Webhook documentation](https://gitlab.synrgy.mobi/groups/devops/-/hooks) and for the -webhook URL enter `https:///gitlab/v1/webhook` +webhook URL enter `https:///gitlab/v1/webhook` diff --git a/docs/docs/about.md b/docs/docs/about.md new file mode 100644 index 00000000..b1968b0a --- /dev/null +++ b/docs/docs/about.md @@ -0,0 +1,2 @@ + +# Project \ No newline at end of file diff --git a/docs/docs/agent-concepts.md b/docs/docs/agent-concepts.md index d80f1e1e..9252eab0 100644 --- a/docs/docs/agent-concepts.md +++ b/docs/docs/agent-concepts.md @@ -4,7 +4,7 @@ ### 1. Autonomous agents -Nous comes with two fully autonomous agents (XML and Python/dynamic), which applying reasoning to break down +Sophia comes with two fully autonomous agents (XML and Python/dynamic), which applying reasoning to break down a user request into a plan to be completed by the available function calls. ### 2. Workflow agents diff --git a/docs/docs/authentication.md b/docs/docs/authentication.md index 1437495f..7775cf86 100644 --- a/docs/docs/authentication.md +++ b/docs/docs/authentication.md @@ -6,7 +6,7 @@ Currently, the valid options are `single_user` and `IAP` ## Single user mode -By default, Nous runs in a single user mode which disables any authentication. On startup the database is queried for +By default, Sophia runs in a single user mode which disables any authentication. On startup the database is queried for a user profile, and if none is found then creates one, using the email from the `SINGLE_USER_EMAIL` environment variable. Th \ No newline at end of file diff --git a/docs/docs/autonomous-agents.md b/docs/docs/autonomous-agents.md index 6ef53a97..2fb30613 100644 --- a/docs/docs/autonomous-agents.md +++ b/docs/docs/autonomous-agents.md @@ -1,6 +1,6 @@ # Autonomous AI Agents -Nous provides two autonomous agents which work to complete the request via a control loop which iteratively (re-)plans and calls the functions available to the agent. +Sophia provides two autonomous agents which work to complete the request via a control loop which iteratively (re-)plans and calls the functions available to the agent. At a high level they share the same internal state, agent memory, human-in-the loop, functional calling history etc. diff --git a/docs/docs/chatbot.md b/docs/docs/chatbot.md new file mode 100644 index 00000000..3448a7ae --- /dev/null +++ b/docs/docs/chatbot.md @@ -0,0 +1,2 @@ +# ChatBot + diff --git a/docs/docs/code-review.md b/docs/docs/code-review.md index f09d9ce6..070841bb 100644 --- a/docs/docs/code-review.md +++ b/docs/docs/code-review.md @@ -1,6 +1,6 @@ # AI Code reviews -Nous has support for AI code reviews of GitLab merge requests. Adding GitHub support is a good candidate for using the Code Editor agent to assist with! +Sophia has support for AI code reviews of GitLab merge requests. Adding GitHub support is a good candidate for using the Code Editor agent to assist with! For the current working proof-of-concept, the configuration files are located in the [/resources](https://github.com/TrafficGuard/nous/tree/preview/resources/codeReview) folder. The next step will to store the configuration in a database. diff --git a/docs/docs/environment-variables.md b/docs/docs/environment-variables.md index 7bf01f35..920babee 100644 --- a/docs/docs/environment-variables.md +++ b/docs/docs/environment-variables.md @@ -78,7 +78,7 @@ This document provides comprehensive details about the environment variables uti **TRACE_SERVICE_NAME** - **Description**: The name of the service for tracing purposes. -- **Default Value**: `nous` +- **Default Value**: `sophia` **TRACE_AUTO_INSTRUMENT** diff --git a/docs/docs/functions.md b/docs/docs/functions.md index 9d0c2f51..d05122da 100644 --- a/docs/docs/functions.md +++ b/docs/docs/functions.md @@ -1,6 +1,6 @@ # LLM Function schemas -Nous provides an automated way to create LLM function schemas, avoiding the duplicate work of creating a function schema separate from the code implementation. +Sophia provides an automated way to create LLM function schemas, avoiding the duplicate work of creating a function schema separate from the code implementation. The *ts-morph* package is used to parse the source code at build-time/runtime to generate the schemas. @@ -37,10 +37,10 @@ The `@funcClass(__filename)` annotation must be on the class so ts-morph can fin The `@func()` annotation must be on each class method to be exposed as a LLM callable function. If the schema files don't exist at runtime then they will automatically be generated. To improve startup time -the schema files are cached under the folder `.nous/functions` and only re-built if the source file modified date is newer. +the schema files are cached under the folder `.sophia/functions` and only re-built if the source file modified date is newer. Also, the schema files can be generated at build time with the `npm run functionSchemas` script. -Function calling agents can transform the object implementing the [FunctionSchema](https://github.com/TrafficGuard/nous/blob/main/src/functionSchema/functions.ts#L13) +Function calling agents can transform the object implementing the [FunctionSchema](https://github.com/TrafficGuard/sophia/blob/main/src/functionSchema/functions.ts#L13) interface into the format required, e.g. the custom XML format, or native function calling types for OpenAI, Anthropic, Gemini etc. The `@func` annotation also adds OpenTelemetry tracing to the function call. diff --git a/docs/docs/getting-started-cli.md b/docs/docs/getting-started-cli.md index ae9cbe51..329e2235 100644 --- a/docs/docs/getting-started-cli.md +++ b/docs/docs/getting-started-cli.md @@ -21,7 +21,7 @@ npm run agent research the latest news about large language models and write a r Without arguments the prompt is read from `src/cli/code-in` otherwise it uses the provided arguments for the prompt. -This is a useful for editing the nous codebase. You could run a command like: +This is a useful for editing the sophia codebase. You could run a command like: ```bash npm run code In the anthropic vertex class update the pricing for claude 3.5 sonnet to be 3 dollars per million input tokens and 15 dollars per million output tokens diff --git a/docs/docs/index.md b/docs/docs/index.md index e1979a3a..bdd7de0b 100644 --- a/docs/docs/index.md +++ b/docs/docs/index.md @@ -1,21 +1,21 @@

- nous logo + nous logo

The open-source TypeScript platform for autonomous AI agents and LLM based workflows

-Nous (Greek: νοῦς) is a term from classical philosophy often associated with intellect or intelligence, represents the human mind's capacity to comprehend truth and reality. +The Ancient Greek word sophía (σοφία) is the abstract noun of σοφός (sophós), which variously translates to "clever, skillful, intelligent, wise" -## The Nous Story +## The Sophia Story -Nous started from a simple goal: to harness AI's potential to enhance real-world productivity, born in DevOps and Platform Engineering space. We envisioned a tool that could: +Sophia started from a simple goal: to harness AI's potential to enhance real-world productivity, born in DevOps and Platform Engineering space. We envisioned a tool that could: - Automate various processes and support requests, and triage build failures. - Review code for compliance with standards and best practices. - Assist with large refactorings, and more. -At TrafficGuard we process billions of events a month for our global clients, [increasing their Ad spend ROI](https://www.trafficguard.ai/case-studies?ref=nous) from bots and other invalid traffic. +At TrafficGuard we process billions of events a month for our global clients, [increasing their Ad spend ROI](https://www.trafficguard.ai/case-studies?ref=sophia) from bots and other invalid traffic. Our platform on Google Cloud comprises projects developed in TypeScript, Python, GoogleSQL, PHP and Terraform, deployed from GitLab. With open source projects typically Python/GitHub focused, and the vendor AI tools being focused in their silos, @@ -42,7 +42,7 @@ Some of the key features include: - Function callable integrations: - Filesystem, Jira, Slack, Perplexity, Gitlab and more - Supports multiple LLMs/Services: - - OpenAI, Anthropic (native & Vertex), Gemini, Groq, Fireworks, Together.ai, DeepSeek, Ollama + - OpenAI, Anthropic (native & Vertex), Gemini, Groq, Fireworks, Together.ai, DeepSeek, Ollama, Cerebras - CLI and Web interface - Human-in-the-loop for: - Budget control @@ -96,11 +96,11 @@ Some of the key features include: ## Code Examples -### Nous vs LangChain +### Sophia vs LangChain -Nous doesn't use LangChain, for [many reasons](https://www.octomind.dev/blog/why-we-no-longer-use-langchain-for-building-our-ai-agents) that [you](https://www.google.com/search?q=langchain+site%3Anews.ycombinator.com) can [read online](https://www.google.com/search?q=langchain+sucks+site%3Areddit.com) +Sophia doesn't use LangChain, for [many reasons](https://www.octomind.dev/blog/why-we-no-longer-use-langchain-for-building-our-ai-agents) that [you](https://www.google.com/search?q=langchain+site%3Anews.ycombinator.com) can [read online](https://www.google.com/search?q=langchain+sucks+site%3Areddit.com) -Let's compare the LangChain document example for Multiple Chains to the equivalent Nous implementation. +Let's compare the LangChain document example for Multiple Chains to the equivalent Sophia implementation. #### LangChain ```typescript @@ -138,7 +138,7 @@ const result = await combinedChain.invoke({ console.log(result); ``` -#### Nous +#### Sophia ```typescript import { llms } from '#agent/context' import { anthropicLLMs } from '#llms/anthropic' @@ -154,7 +154,7 @@ runAgentWorkflow({ llms: anthropicLLMs() }, async () => { }); ``` -The Nous code also has the advantage of static typing with the prompt arguments, enabling you to refactor with ease. +The Sophia code also has the advantage of static typing with the prompt arguments, enabling you to refactor with ease. Using simple control flow allows easy debugging with breakpoints/logging. To run a fully autonomous agent: @@ -195,5 +195,3 @@ export class Jira { ## Contributing We warmly welcome contributions to the project through [issues](https://github.com/TrafficGuard/nous/issues), [pull requests](https://github.com/TrafficGuard/nous/pulls) or [discussions](https://github.com/TrafficGuard/nous/discussions) - -Reach out to us as nous@trafficguard.ai if you'd like support to ramp up as a contributor. \ No newline at end of file diff --git a/docs/docs/observability.md b/docs/docs/observability.md index a7d6072a..f6430b07 100644 --- a/docs/docs/observability.md +++ b/docs/docs/observability.md @@ -24,7 +24,7 @@ Any TypeScript file which is used as an application entry point should being wit Tracing is implemented with OpenTelemetry. The environment variables which configure tracing are: ``` TRACE_AGENT_ENABLED=true -TRACE_SERVICE_NAME=nous +TRACE_SERVICE_NAME=sophia TRACE_AUTO_INSTRUMENT=true TRACE_SAMPLE_RATE=1 ``` diff --git a/docs/docs/setup.md b/docs/docs/setup.md index 94b59e67..c44ce4b7 100644 --- a/docs/docs/setup.md +++ b/docs/docs/setup.md @@ -9,8 +9,8 @@ ## Installation ```bash -git clone https://github.com/TrafficGuard/nous.git -cd nous +git clone https://github.com/TrafficGuard/sophia.git +cd sophia source ./bin/configure ``` The configure script will: @@ -46,12 +46,12 @@ If you want to get running ASAP then in `variables/local.env` update the `DATABA ## Configuration quick start -The `variables/local.env` file contains the configuration when running Nous locally. +The `variables/local.env` file contains the configuration when running Sophia locally. If you have configured Google Cloud then update `TRACE_AGENT_ENABLED` to `true`. -By default, Nous runs in `single_user` authentication mode. A user profile will be created the first time the application is run. -Update the `SINGLE_USER_EMAIL` variable with your email before running Nous for the first time. +By default, Sophia runs in `single_user` authentication mode. A user profile will be created the first time the application is run. +Update the `SINGLE_USER_EMAIL` variable with your email before running Sophia for the first time. The LLM service API keys and integration configurations can be set in web UI, or alternatively in the `variables/local.env` file. Values in the user profile take preferences over the environment configuration values. diff --git a/docs/docs/software-engineer.md b/docs/docs/software-engineer.md index 1f82c7ee..36deab26 100644 --- a/docs/docs/software-engineer.md +++ b/docs/docs/software-engineer.md @@ -5,10 +5,10 @@ AI offers coding capabilities across a spectrum of use cases, from smart IDE aut 1. IDE inline code suggestions 2. IDE context aware chat 3. [Aider](https://aider.chat/) pair-programming -4. Nous Code Editing agent -5. Nous Software Engineer agent +4. Sophia Code Editing agent +5. Sophia Software Engineer agent -The Nous agents build upon the fantastic project [Aider](https://aider.chat/), providing additional layers above it for more autonomous use cases. +The Sophia agents build upon the fantastic project [Aider](https://aider.chat/), providing additional layers above it for more autonomous use cases. ## Code Editing Agent @@ -31,7 +31,7 @@ The [Code Editor Agent](https://github.com/TrafficGuard/nous/blob/main/src/swe/c ### FileSystem -The agent context has a FileSystem, which defaults to the Nous project directory. If you want to use the code editing agent +The agent context has a FileSystem, which defaults to the Sophia project directory. If you want to use the code editing agent on another local repo then set the `RunAgentConfig.fileSystemPath` property, or alternatively set the NOUS_FS environment variable to the repository path. ### Project Info @@ -46,7 +46,7 @@ If the agent makes a mistake in the detection then manually edit the projectInfo At TrafficGuard we have projects in Terraform HCL, JavaScript/TypeScript, PHP and Python. -Nous aims to be a flexible platform, and one example is the language specific tooling. The project detection also detects which language a project uses. +Sophia aims to be a flexible platform, and one example is the language specific tooling. The project detection also detects which language a project uses. The initial `LanguageTools` interface has the `generateProjectMap` and `installPackage` methods. diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml index 00d16f81..f9093551 100644 --- a/docs/mkdocs.yml +++ b/docs/mkdocs.yml @@ -1,5 +1,5 @@ -site_name: nous.ai -site_url: https://nous.trafficguard.ai/ +site_name: sophia | ai +site_url: https://sophia.dev/ theme: name: material palette: @@ -26,8 +26,8 @@ markdown_extensions: emoji_index: !!python/name:material.extensions.emoji.twemoji emoji_generator: !!python/name:material.extensions.emoji.to_svg -repo_url: https://github.com/trafficguard/nous -repo_name: trafficguard/nous +repo_url: https://github.com/trafficguard/sophia +repo_name: trafficguard/sophia nav: - index.md diff --git a/frontend/.yo-rc.json b/frontend/.yo-rc.json index 2f12ae0b..76e022bc 100644 --- a/frontend/.yo-rc.json +++ b/frontend/.yo-rc.json @@ -8,7 +8,7 @@ "skipQuickstart": false, "initGit": true, "usePrefix": true, - "appName": "nous-ng", + "appName": "sophia-ng", "target": ["web"], "ui": "material", "layout": "side-menu", @@ -17,7 +17,7 @@ "tools": ["prettier", "hads", "jest"], "utility": ["lodash", "datefns"], "deploy": "firebase", - "projectName": "nous-ng", + "projectName": "sophia-ng", "packageManager": "npm", "mobile": [], "desktop": [], diff --git a/frontend/README.md b/frontend/README.md index fea64032..cf775765 100644 --- a/frontend/README.md +++ b/frontend/README.md @@ -1,4 +1,4 @@ -# nous-ng +# sophia-ng This project was generated with [ngX-Rocket](https://github.com/ngx-rocket/generator-ngx-rocket/) version 11.0.0 diff --git a/frontend/angular.json b/frontend/angular.json index a873aaf1..9fdd93c6 100644 --- a/frontend/angular.json +++ b/frontend/angular.json @@ -3,7 +3,7 @@ "version": 1, "newProjectRoot": "projects", "projects": { - "nous-ng": { + "sophia-ng": { "projectType": "application", "schematics": { "@schematics/angular:component": { @@ -70,10 +70,10 @@ "builder": "@angular-devkit/build-angular:dev-server", "configurations": { "production": { - "browserTarget": "nous-ng:build:production" + "browserTarget": "sophia-ng:build:production" }, "development": { - "browserTarget": "nous-ng:build:development" + "browserTarget": "sophia-ng:build:development" }, "ci": { "progress": false @@ -84,7 +84,7 @@ "extract-i18n": { "builder": "@angular-devkit/build-angular:extract-i18n", "options": { - "browserTarget": "nous-ng:build" + "browserTarget": "sophia-ng:build" } }, "test": { @@ -110,11 +110,11 @@ "cypress-run": { "builder": "@cypress/schematic:cypress", "options": { - "devServerTarget": "nous-ng:serve" + "devServerTarget": "sophia-ng:serve" }, "configurations": { "production": { - "devServerTarget": "nous-ng:serve:production" + "devServerTarget": "sophia-ng:serve:production" } } }, @@ -128,18 +128,18 @@ "e2e": { "builder": "@cypress/schematic:cypress", "options": { - "devServerTarget": "nous-ng:serve" + "devServerTarget": "sophia-ng:serve" }, "configurations": { "production": { - "devServerTarget": "nous-ng:serve:production" + "devServerTarget": "sophia-ng:serve:production" } } } } } }, - "defaultProject": "nous-ng", + "defaultProject": "sophia-ng", "cli": { "analytics": false } diff --git a/frontend/docs/readme.md b/frontend/docs/readme.md index 6dc97ea8..23532818 100644 --- a/frontend/docs/readme.md +++ b/frontend/docs/readme.md @@ -1,4 +1,4 @@ -# nous-ng +# sophia-ng Welcome to the project documentation! diff --git a/frontend/package-lock.json b/frontend/package-lock.json index 419852b9..f8769653 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -1,11 +1,11 @@ { - "name": "nous-ng", + "name": "sophia-ng", "version": "1.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "nous-ng", + "name": "sophia-ng", "version": "1.0.0", "hasInstallScript": true, "dependencies": { diff --git a/frontend/package.json b/frontend/package.json index bd638565..80b4eda0 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,5 +1,5 @@ { - "name": "nous-ng", + "name": "sophia-ng", "version": "1.0.0", "private": true, "scripts": { @@ -12,10 +12,10 @@ "lint:ci": "ng lint && npm run prettier:check", "stylelint": "stylelint \"src/**/*.scss\"", "test": "npm run write:env -s && ng test", - "test:ci": "npm run write:env -s && npm run lint:ci -s && ng run nous-ng:test:ci", + "test:ci": "npm run write:env -s && npm run lint:ci -s && ng run sophia-ng:test:ci", "e2e": "npm run write:env -s && ng e2e", - "cypress:open": "npm run write:env -s && ng run nous-ng:cypress-open", - "cypress:run": "npm run write:env -s && ng run nous-ng:cypress-run", + "cypress:open": "npm run write:env -s && ng run sophia-ng:cypress-open", + "cypress:run": "npm run write:env -s && ng run sophia-ng:cypress-run", "translations:extract": "ngx-translate-extract --input ./src --output ./src/translations/template.json --format=json --clean --sort", "docs": "hads ./docs -o", "write:env": "ngx-scripts env npm_package_version SERVER_URL GCLOUD_PROJECT FIRESTORE_DATABASE AUTH", diff --git a/frontend/src/index.html b/frontend/src/index.html index c6335ce8..70cf0b60 100644 --- a/frontend/src/index.html +++ b/frontend/src/index.html @@ -4,7 +4,7 @@ - nous.ai + sophia  |  ai diff --git a/frontend/src/translations/en-US.json b/frontend/src/translations/en-US.json index 14c3a949..0f923bfb 100755 --- a/frontend/src/translations/en-US.json +++ b/frontend/src/translations/en-US.json @@ -1,5 +1,5 @@ { - "APP_NAME": "nous.ai", + "APP_NAME": "sophia  |  ai", "About": "About", "Hello world !": "Hello world !", "Home": "Home", diff --git a/package.json b/package.json index 857aff0b..75c5c032 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "@trafficguard/nous", + "name": "@trafficguard/sophia", "version": "0.0.1-dev", "description": "AI agent & LLM app platform", "private": true, diff --git a/src/functions/storage/filesystem.ts b/src/functions/storage/filesystem.ts index fe34c570..8e7a9de9 100644 --- a/src/functions/storage/filesystem.ts +++ b/src/functions/storage/filesystem.ts @@ -35,7 +35,7 @@ type FileFilter = (filename: string) => boolean; /** * Provides functions for LLMs to access the file system. Tools should generally use the functions as * - They are automatically included in OpenTelemetry tracing - * - They use the working directory, so Nous can perform its actions outside the process running directory. + * - They use the working directory, so Sophia can perform its actions outside the process running directory. * * The FileSystem is constructed with the basePath property which is like a virtual root. * Then the workingDirectory property is relative to the basePath. diff --git a/src/swe/codeEditingAgent.ts b/src/swe/codeEditingAgent.ts index f5ff9458..f52069dc 100644 --- a/src/swe/codeEditingAgent.ts +++ b/src/swe/codeEditingAgent.ts @@ -167,13 +167,13 @@ export class CodeEditingAgent { if (compileErrorSummaries.length) { compileFixRequirements += '\n'; - for (const summary of compileErrorSummaries) compileFixRequirements += '${summary}\n'; + for (const summary of compileErrorSummaries) compileFixRequirements += `${summary}\n`; compileFixRequirements += '\n'; } compileFixRequirements += compileErrorSearchResults.map((result) => `${result}\n`).join(); - compileFixRequirements += `${compileErrorAnalysis.compilerOutput}\n\n`; + compileFixRequirements += `${compileErrorAnalysis.compilerOutput}\n\n`; if (compiledCommitSha) { - compileFixRequirements += `${await git.getDiff(compiledCommitSha)}\n`; + compileFixRequirements += `\n${await git.getDiff(compiledCommitSha)}\n`; compileFixRequirements += 'The above diff has introduced compile errors. With the analysis of the compiler errors, first focus on analysing the diff for any obvious syntax and type errors and then analyse the files you are allowed to edit.\n'; } else { diff --git a/src/swe/codeEditor.ts b/src/swe/codeEditor.ts index 8019e27e..5b1a8155 100644 --- a/src/swe/codeEditor.ts +++ b/src/swe/codeEditor.ts @@ -73,7 +73,7 @@ export class CodeEditor { ); } - // User a folder in Nous process directory, not the FileSystem working directory + // User a folder in Sophia process directory, not the FileSystem working directory // as we want all the 'system' files in one place. const llmHistoryFolder = join(process.cwd(), '.nous/aider/llm-history'); await promisify(fs.mkdir)(llmHistoryFolder, { recursive: true }); @@ -90,7 +90,7 @@ export class CodeEditor { // Due to limitations in the provider APIs, caching statistics and costs are not available when streaming responses. // --map-tokens=2048 - // Use the Python from the Nous .python-version as it will have aider installed + // Use the Python from the Sophia .python-version as it will have aider installed const cmd = `${getPythonPath()} -m aider --no-check-update --no-stream --yes ${modelArg} --llm-history-file="${llmHistoryFile}" --message-file=${messageFilePath} ${filesToEdit .map((file) => `"${file}"`) .join(' ')}`; @@ -142,7 +142,7 @@ export class CodeEditor { } export function getPythonPath() { - // Read the Nous .python-version file + // Read the Sophia .python-version file const pythonVersionFile = path.join(process.cwd(), '.python-version'); const pythonVersion = fs.readFileSync(pythonVersionFile, 'utf8').trim(); // Use pyenv to find the path of the specified Python version