Skip to content

Commit

Permalink
feat: restructure directories
Browse files Browse the repository at this point in the history
Signed-off-by: Akihiko Kuroda <akihikokuroda2020@gmail.com>
  • Loading branch information
akihikokuroda committed Oct 25, 2024
1 parent f991f22 commit fb4c0f9
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 38 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"clean": "rimraf dist",
"build": "yarn clean && yarn ts:check && tsup",
"ts:check": "tsc --noEmit && tsc -p tsconfig.examples.json --noEmit",
"start": "tsx --tsconfig tsconfig.examples.json",
"start": "tsx",
"lint": "yarn eslint",
"lint:fix": "yarn eslint --fix",
"format": "yarn prettier --check .",
Expand Down
2 changes: 1 addition & 1 deletion tools/airtable/airtableTool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

import { describe, test } from "vitest";
import { AirtableTool, AirtableToolOptions } from "@/tools/airtable.js";
import { AirtableTool, AirtableToolOptions } from "@tools/airtable/airtable.js";

import { setupServer } from "msw/node";

Expand Down
5 changes: 2 additions & 3 deletions tools/airtable/examples/airTableToolAgent.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import "dotenv/config.js";
import { BAMChatLLM } from "bee-agent-framework/adapters/bam/chat";
import { BeeAgent } from "bee-agent-framework/agents/bee/agent";
import { createConsoleReader } from "@/helpers/io.js";
import { createConsoleReader } from "@tools/examples/helpers/io.js";
import { FrameworkError } from "bee-agent-framework/errors";
import { TokenMemory } from "bee-agent-framework/memory/tokenMemory";
import { Logger } from "bee-agent-framework/logger/logger";
Expand All @@ -39,8 +39,7 @@ import { DuckDuckGoSearchTool } from "bee-agent-framework/tools/search/duckDuckG
import { WikipediaTool } from "bee-agent-framework/tools/search/wikipedia";

// AirTable tool
// import { AirtableTool } from "bee-community-tools/tools/airtable";
import { AirtableTool } from "bee-community-tools/tools/airtable/airtableTool";
import { AirtableTool } from "@tools/airtable/airtable.js";

const AIRTABLE_TOKEN: string = parseEnv("AIRTABLE_TOKEN", z.string());
const AIRTABLE_BASE: string = parseEnv("AIRTABLE_BASE", z.string());
Expand Down
9 changes: 3 additions & 6 deletions tools/openLibrary/examples/manyToolsAgent.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import "dotenv/config.js";
import { BAMChatLLM } from "bee-agent-framework/adapters/bam/chat";
import { BeeAgent } from "bee-agent-framework/agents/bee/agent";
import { createConsoleReader } from "@/helpers/io.js";
import { createConsoleReader } from "@helpers/io.js";
import { FrameworkError } from "bee-agent-framework/errors";
import { TokenMemory } from "bee-agent-framework/memory/tokenMemory";
import { Logger } from "bee-agent-framework/logger/logger";
Expand All @@ -36,13 +36,10 @@ import {
// core tools
import { DuckDuckGoSearchTool } from "bee-agent-framework/tools/search/duckDuckGoSearch";
import { WikipediaTool } from "bee-agent-framework/tools/search/wikipedia";
// import { OpenMeteoTool } from "bee-agent-framework/tools/weather/openMeteo";
// import { ArXivTool } from "bee-agent-framework/tools/arxiv";

// contrib tools
// import { HelloWorldTool } from "@/tools/helloWorld.js";
import { OpenLibraryTool } from "bee-community-tools/tools/openLibrary";
import { ImageDescriptionTool } from "bee-community-tools/tools/imageDescription";
import { OpenLibraryTool } from "@tools/openLibrary/openLibrary.js";
import { ImageDescriptionTool } from "@tools/imageDescriptions/imageDescription.js";

Logger.root.level = "silent"; // disable internal logs
const logger = new Logger({ name: "app", level: "trace" });
Expand Down
13 changes: 0 additions & 13 deletions tools/src/tsconfig.json

This file was deleted.

13 changes: 0 additions & 13 deletions tools/tsconfig.json

This file was deleted.

3 changes: 2 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
"paths": {
"@/*": ["./src/*"],
"@tests/*": ["./tests/*"],
"@tools/*": ["./tools/*"]
"@tools/*": ["./tools/*"],
"@helpers/*": ["./tools/examples/helpers/*"]
},
"useUnknownInCatchVariables": false
},
Expand Down

0 comments on commit fb4c0f9

Please sign in to comment.