Commit Graph

172 Commits

Author SHA1 Message Date
Roberto
a5a6e25a89 Update the background 2026-05-03 22:52:10 +02:00
Roberto
df8cbb5c35 Update note management from db vector to index 2026-04-30 00:11:25 +02:00
Roberto
d0b344beec timeline resize view 2026-04-29 23:13:29 +02:00
Roberto
1f4adfca90 Update project circle 2026-04-29 14:42:21 +02:00
Roberto
259ab50b25 Update projects page view 2026-04-29 09:31:15 +02:00
Roberto
a04c2434b6 fix tools calls 2026-04-27 09:15:04 +02:00
Roberto
c291fc689a timeevent and date formt fix 2026-04-26 21:06:20 +02:00
Roberto
b61a6de73a Step 1: Improve timeline event view 2026-04-23 00:07:18 +02:00
Roberto
f2a68ee5f6 update tasks visualization 2026-04-22 00:13:22 +02:00
Roberto
0c43f5633f flex-wrap to filter section in the task page 2026-04-21 23:23:59 +02:00
Roberto
4ebf0d4062 Keep project client open 2026-04-21 23:17:27 +02:00
Roberto
244d53f93d Update note view and sidebar where now it visible the project 2026-04-21 23:02:01 +02:00
Roberto
8dceacc2ce Review project page 2026-04-21 21:42:49 +02:00
Roberto
7244810fe1 add daily brief agent 2026-04-19 14:47:47 +02:00
Roberto Musso
e9c790e017 PHASE 4 — Settings > Memory UI (Electron renderer) 2026-04-17 17:04:50 +02:00
Roberto Musso
9b32d834b3 Update setting page 2026-04-15 11:44:40 +02:00
Roberto Musso
333b6cb769 feat(notifications): add sonner toasts to auth and onboarding flows 2026-04-12 18:17:18 +02:00
Roberto Musso
87c444e78d feat(notifications): add sonner toasts to all CRUD operations 2026-04-12 18:13:52 +02:00
Roberto Musso
811759dddb feat(notifications): replace settings saved-state patterns with sonner toasts 2026-04-12 18:06:50 +02:00
Roberto Musso
275edab4bf feat(notifications): add sonner toast foundation with useNotify hook and i18n keys 2026-04-12 18:04:29 +02:00
Roberto Musso
0371a46731 feat(i18n): add multilanguage support (EN/IT/ES/FR/DE) with optimized shared keys
- Add i18next + react-i18next with bundled JSON translations
- Translate all pages: Home, Tasks, Timeline, Projects, Settings, Auth, Agents
- Language selector in Settings > General syncs to electron-store + backend memory
- AI daily brief and agent responses respect selected language
- Optimize translation files: consolidate 16 duplicate keys into common.* namespace
  (add, rename, save, edit, delete, saving, deleting, creating, renameDescription, deleteTitle)
- LanguageSync component in root restores persisted language on startup
2026-04-12 00:33:14 +02:00
Roberto Musso
cd8f6a6751 feat: onboarding wizard - multi-step flow, locale detection, profile settings, user_name in core memory 2026-04-11 23:40:12 +02:00
Roberto Musso
dd98aaaf4d feat: add seed script for populating database with fake data and logging for agent triggers 2026-04-11 02:13:56 +02:00
Roberto Musso
20bc28e59b feat: replace _cachedPassword with device-specific backup key
Add backup-key.ts that generates a random 256-bit key on first use and
persists it via safeStorage + electron-store (same pattern as token.ts).
Remove _cachedPassword and getCachedPassword() from AuthManager — they
were unused since BackupManager does not exist yet. Social-login users
can now use backup features without being tied to a password.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-10 13:41:48 +02:00
Roberto Musso
5d112c8dfd feat: implement Google OAuth flow — deep link, auth-manager, login UI, avatar
Step 3 (deep link + auth manager):
- forge.config.ts: register adiuvai:// protocol for packaged app
- index.ts: single-instance lock, setAsDefaultProtocolClient (dev + prod),
  second-instance (Windows/Linux) and open-url (macOS) handlers
- auth-manager.ts: loginWithOAuth() opens browser + awaits deep-link promise;
  handleOAuthCallback() parses adiuvai://oauth/callback, exchanges code via
  POST /auth/oauth/{provider}/callback, resolves pending promise
- router/index.ts: auth.loginWithOAuth tRPC mutation

Step 4 (UI + avatar):
- LoginForm.tsx: Google button with inline SVG icon, divider, "Waiting for
  browser..." pending state; isBusy guards both mutations
- AppShell.tsx: AvatarImage added to NavUser (sidebar trigger + dropdown);
  avatarUrl propagated through AppSidebarProps and NavUser types
- AccountSection.tsx: avatar with photo/initials fallback, display name, email
- api-types.ts: avatarUrl added to UserProfileSchema (camelCase, nullable)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-10 13:04:02 +02:00
Roberto Musso
27bc9d90af feat: enhance agent scheduling and prompt builder functionality 2026-04-10 08:45:45 +02:00
Roberto Musso
016c44c6f0 remove unecessary indications 2026-04-09 00:41:02 +02:00
Roberto Musso
02a0f3635b update app name 2026-04-08 23:27:03 +02:00
Roberto
109551f713 Merge branch 'develop' of https://git.muticolturano.com/Adiuva/adiuva into develop 2026-04-08 23:14:31 +02:00
f129b3ba43 Merge branch 'develop' of https://git.muticolturano.com/Adiuva/adiuva into develop 2026-04-08 22:04:43 +02:00
7f0c6f45b0 feat(local-agent-v2): step 5 — migrate promptTemplate → agentConfig in FE
- store.ts: LocalAgentLocalConfig.promptTemplate (string) → agentConfig (Record | null)
- agent-scheduler.ts + router runNow: send agentConfig object to trigger, drop customAgentPrompt
- api-types.ts: WsJourneyReplySchema + LocalAgentConfigSchema + JourneyMessageSchema use agentConfig
- WsJourneyStartSchema: existingTemplate → existingConfig (aligns with backend existing_config field)
- backend-client.ts: JourneyListener + sendJourneyStart + journey_reply handler use agentConfig
- router/index.ts: local agent create/update accept agentConfig; journey router returns agentConfig
- types.ts + AgentsSection + JourneyDialog: promptTemplate → agentConfig throughout
- JourneyDialog: parses JSON agentConfig string → object; shows AgentConfigSummary preview
- PromptBuilderChat: adds onConfigUpdate callback for local agent path (cloud keeps onPromptUpdate)
- InlineAgentCreationStepper: local path uses agentConfig state; cloud path keeps promptTemplate

Cloud agents are intentionally NOT migrated — they retain promptTemplate string.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-08 22:03:26 +02:00
Roberto
2caea8e21d rebrand: Adiuva → adiuvAI with new compass logo
Replace generic star icon and "Adiuva" text with new compass mark and
"adiuvAI" wordmark across sidebar, login form, and AI chat header.
Add app icon (PNG/ICO) and configure Forge packager and BrowserWindow.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-08 15:26:44 +02:00
Roberto
b23c4ef255 Merge branch 'develop' of https://git.muticolturano.com/Adiuva/adiuva into develop 2026-04-08 09:54:12 +02:00
Roberto
801ae43000 Add logo brand 2026-04-08 09:53:48 +02:00
bd9af5ddd6 refactor: remove backup, storage, and plugin types from Electron app
- Delete src/main/backup/ (backup-manager, e2e-crypto, sync-queue)
- Remove backup lifecycle from index.ts and router
- Remove syncQueue table from db/schema.ts
- Remove backupEnabled/backupIntervalHours/lastBackupAt from store
- Remove uploadBackup/downloadBackup from backend-client
- Update embed URL to /api/v1/chat/embed
- Remove PluginListing, InstalledPlugin from batch-types
- Remove PermissionGrant, BackupMetadata from api-types
2026-04-08 00:48:00 +02:00
3ae9e450be Fix ProjectSidebar scroll and style native scrollbar
- Constrain SidebarProvider to h-full to close height chain
- Replace Radix ScrollArea in ProjectSidebar with overflow-y-auto div
  (Radix needs explicit pixel height; flex-1 alone is unreliable)
- Add min-h-0 to ProjectSidebar root to allow flex shrink
- Style native webkit scrollbar to match shadcn ScrollBar component
  (w-2.5, bg-border thumb, rounded-full, transparent track/corner)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-20 23:44:43 +01:00
7616153345 Remove isApproved from tasks, rework agent runner, fix layout overflow
- Remove isApproved column from tasks DB schema and migration; drop column on startup
- Remove isApproved from tRPC router (list, create, update queries)
- Remove isApproved filter from KanbanBoard and ProjectDetail approve/reject UI
- AI-generated tasks now auto-approved; show Sparkles icon via isAiSuggested flag
- Fix tasks page width overflow: add min-w-0 to SidebarInset in AppShell
- Fix task title overflow: truncate with ellipsis inside TaskRow
- Fix tasks toolbar layout: shrink-0 on right side, fixed w-56 on search input

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-20 22:20:55 +01:00
0c21f47a59 removed unused files 2026-03-20 12:47:33 +01:00
7256f1ef4e Fix runNow: pass agentId and create run row in local SQLite
The manual 'Run now' path was missing both agentId in the trigger
request (so BE couldn't echo it in run_context) and the agentRuns
insert after the trigger responded, so manually-triggered runs never
appeared in the history sheet.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-20 11:54:54 +01:00
bf635d9c30 Always record agent run even when no actions are taken
Create the agentRuns row immediately after the trigger POST responds,
before any tool calls arrive. This ensures runs with zero mutations
(agent found nothing to create/update) still appear in the history sheet.

Removed the redundant onConflictDoNothing guard from recordRunAction
since the row is guaranteed to exist by trigger time.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-20 10:46:42 +01:00
5add259348 Fix await in sync WS message handler for run_complete
Wrap the async db.update in void (async () => {})() like the tool_call
case does — the ws.on('message') callback is synchronous.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-20 10:16:18 +01:00
198fd62ef2 Add agent run history sheet with action breakdown
- agent.runs tRPC procedure now queries local SQLite agentRuns table
  (previously fetched from backend) and joins action counts per run
- agent.runActions procedure added for lazy-loading individual actions
  when a run is expanded in the sheet
- AgentRunHistorySheet: slide-in sheet opened via History button on the
  agent card; shows runs with status/duration/action summary; each run
  is expandable to list individual actions (created/updated/deleted)
  with entity type and title
- AgentRow: adds History button, removes embedded AgentRunLog from
  expanded config section

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-20 10:11:40 +01:00
34a771bee3 Implement agent run logging in local SQLite
Protocol:
- RunContextSchema added to api-types — attached to WsToolCall frames
  originating from batch runs; type/runId/agentId identify the run
- WsRunCompleteSchema added — server sends this when a batch run ends

Database:
- agent_runs table: one row per run (id, agentId, status, startedAt, completedAt)
- agent_run_actions table: one row per mutating tool call
  (verb: created/updated/deleted, entityType, entityId, entityTitle)

Logging logic (backend-client.ts):
- On tool_call with runContext: ensure agentRuns row exists, insert
  agentRunActions for insert/update/delete actions
- On run_complete: update agentRuns status and completedAt

Scheduler passes agentId in the trigger POST so the backend echoes it
back in run_context for correct attribution.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-20 09:46:48 +01:00
65a08838c9 Truncate WS log output to 200 chars
Prevents large tool_result payloads from flooding the dev console.
Both send and receive logs now append … when the serialised frame
exceeds 200 characters.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-18 00:04:16 +01:00
8b5a05a16e Refactor settings page into pluggable components
- Split monolithic settings.tsx (~1500 lines) into focused components under
  src/renderer/components/settings/: GeneralSection, AccountSection,
  AgentsSection, AgentRow, LocalAgentConfigPanel, CloudAgentConfigPanel,
  TemplateSelectCard, PromptBuilderChat, InlineAgentCreationStepper,
  JourneyDialog, SettingsCard, and shared types/constants
- Hide agents list while creation stepper is open
- Use ScrollArea (app scroll primitive) in PromptBuilderChat
- Fix done-state handling: filter empty AI messages, show hardcoded
  confirmation bubble only once, move saved badge below chat, keep
  input enabled after prompt is saved so user can keep refining
- Wrap LocalAgentConfigPanel footer buttons with flex-wrap for narrow cards
- Update Agents section title/subtitle copy

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 23:52:39 +01:00
6a87590176 Update shadcn to v4, fix sendHomeRequest call signature, refresh skills lock
- Upgrade shadcn from 3.8.5 to 4.0.8
- Add missing session_id parameter to sendHomeRequest calls in orchestrator
- Update skills-lock.json computed hashes

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-17 16:34:07 +01:00
cd4644637b Wire journey chat to WS backend and handle end-of-conversation
- Rewrite PromptBuilderChat to use real WS journey mutations with
  button-to-start pattern, loading states, and markdown rendering
- Add isDone state to both PromptBuilderChat and JourneyDialog so
  input is disabled and a confirmation banner shown after prompt generation
- Extract and save promptTemplate via onPromptUpdate when BE sends done=true

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-17 16:26:21 +01:00
9fd441e7d7 Refactor Local Directory Monitor Agent to two-phase BE-orchestrated architecture
Replace the old single-pass FE file-reader flow (agent_run → agent_data →
agent_complete) with a BE-orchestrated two-phase execution where the BE's LLM
calls filesystem tools on the FE via tool_call/tool_result WS round-trips.

Key changes:
- Remove deprecated file-reader.ts and agent_run/agent_data/agent_complete frames
- Add list_directory, read_file_content, get_file_metadata handlers to DrizzleExecutor
- Migrate journey setup from REST to WebSocket (journey_start/message/reply frames)
- Store agent configs locally in electron-store (no longer on BE)
- Add agent scheduler for periodic auto-trigger via POST /agents/trigger
- Update device_hello to use local agent configs
- Remove fileExtensions from agent config, switch to single directory path
- Add agent.canCreate quota check mutation

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-17 11:05:08 +01:00
b7ddc95171 Udpate task page 2026-03-16 08:53:08 +01:00
488dab7aa1 Refine floating chat session lifecycle and home page glass effects
- Floating chat: reset session_id only on user-initiated page navigation,
  not when closed via X/Escape (session persists for reopening same context)
- Home buttons (sidebar trigger + new chat): add frosted glass background
  so they remain legible when chat messages scroll behind them
- Daily brief toast: match frosted glass opacity/blur to button treatment

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 00:53:39 +01:00