Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
25adb40
refactor: Update supabase types and add task-related functions
khaosans Nov 27, 2024
dd2c728
refactor: Update supabase types and add task-related functions
khaosans Nov 27, 2024
ce99eac
refactor: Update supabase subscription in chat stream route
khaosans Nov 27, 2024
16bab22
refactor: Update supabase subscription in chat stream route
khaosans Nov 27, 2024
ef1086c
refactor: Update supabase subscription and types, and add task-relate…
khaosans Nov 27, 2024
c24e6d9
refactor: Update supabase subscription and types, and add task-relate…
khaosans Nov 27, 2024
8206e8e
feat: Add new hooks for local storage and window size
khaosans Nov 27, 2024
418728d
feat: Add new hooks for local storage and window size
khaosans Nov 27, 2024
3597077
feat: Add new hooks for local storage and window size
khaosans Nov 27, 2024
67e9bd0
refactor: Update message component and add suggested actions
khaosans Nov 27, 2024
92d7dbe
Initial commit: Elron AI chatbot with blockchain integration
khaosans Nov 27, 2024
f5c4fd2
feat: Add OpenAIStreamConfig interface
khaosans Nov 27, 2024
021221e
feat: Add WeatherParams, CryptoPriceParams, and FunctionResponse inte…
khaosans Nov 27, 2024
8ac6988
feat: Add empty files for queue, mutations, tasks route, taskProcesso…
khaosans Nov 27, 2024
0e80960
feat: Add SettingsProvider component
khaosans Nov 27, 2024
4b50db8
feat: Add unit tests for SettingsProvider component
khaosans Nov 27, 2024
f653bcd
chore: Update package.json and pnpm-lock.yaml
khaosans Nov 27, 2024
e97024f
Revert "feat: Add empty files for queue, mutations, tasks route, task…
khaosans Nov 27, 2024
7309d98
refactor: Update environment variable name for OpenAI API key
khaosans Nov 27, 2024
0220ebf
refactor: Update OpenAI model names in chat route
khaosans Nov 28, 2024
7418835
refactor: Update data-fetching test and chat route test
khaosans Nov 28, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ NEXT_PUBLIC_CDP_API_KEY_PRIVATE_KEY=your_cdp_private_key_here
# Environment
NEXT_PUBLIC_ENVIRONMENT=localhost
NEXT_PUBLIC_SITE_URL=http://localhost:3000
NEXT_PUBLIC_APP_URL=http://localhost:3000

# WalletConnect
NEXT_PUBLIC_WALLET_CONNECT_PROJECT_ID=your_wallet_connect_project_id_here
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# AI Chat Bot with Blockchain Integration
# Elron - AI Web3 Chatbot with Blockchain Integration

A sophisticated AI chat interface built with Next.js, featuring blockchain wallet integration, real-time content generation, and image handling capabilities. This project combines the power of AI with blockchain technology to provide a secure, intelligent chat experience.

Expand Down
32 changes: 11 additions & 21 deletions __tests__/app/data-fetching.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,30 +16,20 @@ describe("Data Fetching Architecture", () => {
from: vi.fn().mockReturnThis(),
select: vi.fn().mockResolvedValue({ data: [], error: null }),
};
vi.mocked(createClient).mockReturnValue(mockSupabase as any);
vi.mocked(cookies).mockReturnValue({
get: () => ({ value: "mock-cookie" }),
} as any);

const result = await mockSupabase.from("conversations").select();

expect(result.error).toBeNull();
expect(mockSupabase.from).toHaveBeenCalledWith("conversations");
});

it("should handle client-side data fetching", async () => {
const mockSupabase = {
from: vi.fn().mockReturnThis(),
select: vi.fn().mockResolvedValue({
data: [{ id: 1, title: "Test" }],
error: null,
}),
const mockCookieStore = {
get: vi.fn().mockReturnValue({ value: "mock-cookie" }),
set: vi.fn(),
};
vi.mocked(createClient).mockReturnValue(mockSupabase as any);

const result = await mockSupabase.from("conversations").select();
vi.mocked(createClient).mockResolvedValue(mockSupabase as any);
vi.mocked(cookies).mockReturnValue(mockCookieStore as any);

const supabase = await createClient();
const result = await supabase.from("conversations").select();

expect(result.data).toHaveLength(1);
expect(result.data[0]).toHaveProperty("title", "Test");
expect(result.error).toBeNull();
expect(mockSupabase.from).toHaveBeenCalledWith("conversations");
expect(mockCookieStore.get).toHaveBeenCalled();
});
});
34 changes: 0 additions & 34 deletions __tests__/architecture/app-config.test.ts

This file was deleted.

78 changes: 0 additions & 78 deletions __tests__/architecture/app-router.test.ts

This file was deleted.

31 changes: 0 additions & 31 deletions __tests__/architecture/app-structure.test.ts

This file was deleted.

30 changes: 0 additions & 30 deletions __tests__/architecture/dependencies.test.ts

This file was deleted.

25 changes: 0 additions & 25 deletions __tests__/architecture/env.test.ts

This file was deleted.

12 changes: 0 additions & 12 deletions __tests__/architecture/file-structure.test.ts

This file was deleted.

59 changes: 0 additions & 59 deletions __tests__/architecture/routing-conventions.test.ts

This file was deleted.

36 changes: 0 additions & 36 deletions __tests__/architecture/routing.test.ts

This file was deleted.

25 changes: 0 additions & 25 deletions __tests__/architecture/structure.test.ts

This file was deleted.

Loading