agentleFS
iblaiiblai/base/skills/agents/iblai-vibe-agent-task/SKILL.md

iblai-vibe-agent-task

Skill222 starsChanged 12 days agoMITView on GitHub

Add the agent Tasks tab (schedule prompts the agent runs on its own -- once, daily, weekly or monthly -- and read each run's log) to your Next.js app. Use when the user mentions scheduled tasks, recurring agent jobs, cron, daily summaries, reminders the agent sends itself, or periodic agents. For the agent's other settings see /iblai-vibe-agent.

  • Reads credentials
  • Installs packages

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 1 is distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Add the agent Tasks tab -- prompts the agent runs on a schedule, without anyone asking, and a log of every run.

    line 12
  2. Very specific:

    Look for iblai.env in the project root with PLATFORM, DOMAIN, and TOKEN.

    line 65
  3. Very specific:

    All from @iblai/iblai-js/data-layer.

    line 205
  4. Very specific:

    Run /iblai-vibe-ops-test before telling the user the work is ready, and give every page, control and state this skill added its own …

    line 210

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

/iblai-vibe-agent-task

Add the agent Tasks tab -- prompts the agent runs on a schedule, without anyone asking, and a log of every run. Scope: per agent. Each task is a periodic agent run that belongs to this agent. This is one tab in the agent-settings family indexed by /iblai-vibe-agent; it shares the AgentSettingsProvider wrapper with every other tab.

Tasks -- search, a date filter (Select Date, the day a task starts), Schedule Task on the right, the counters (Total Tasks, Completed, Failed) in one strip, and the task list: name, time, repeat, a status icon and a delete icon. The list shows as many tasks as fit the space and pages the rest, so it never scrolls (between 768 and 1023px wide it shows 5 a page instead). The status icon is grey; hover it (or use a screen reader) for the word. It follows the latest run: Running, Failed or Completed; before the first run it is Scheduled (or Disabled). With no tasks the tab shows one dashed empty box.

Image: Tasks tab -- tasks

Schedule Task -- a calendar for the start date, then Task Name, Task Prompt, Time, Repeat (Don't repeat / Daily / Weekly / Monthly) and Notify me by email. The start must be in the future, or the dialog says so and Schedule Task stays disabled.

Image: Tasks tab -- Schedule Task

Task Logs -- click a task to list its runs (status, when, the start of the output), as many as fit, with a pager. Click a run for Log Details: status, Created, Started and Ended times, and the full output.

Image: Tasks tab -- Task Logs

Delete Task -- the trash icon asks for confirmation; the task stops.

Image: Tasks tab -- Delete Task

On a phone (below 768px) -- each task is a card, the date filter is an icon that opens a sheet from the bottom, and a "Page x of y" pager replaces the page numbers. Tapping a task opens Task Logs full screen, with Back.

Image: Tasks tab on a phone Image: Task Logs on a phone

Common setup (brand, conventions, env files, verification): see docs/skill-setup.md.

Prerequisites

  • Auth set up (/iblai-vibe-auth, or vibe-starter).
  • AgentSettingsProvider wraps the route (/iblai-vibe-agent §1).
  • @iblai/iblai-js@^3.1.0 (resolves @iblai/web-containers 2.1.0). Check with pnpm why @iblai/web-containers.
  • A real agent UUID. Ask the user; never invent one.

Step 1: Check Environment

Look for iblai.env in the project root with PLATFORM, DOMAIN, and TOKEN. If it is missing, tell the user: "You need an iblai.env with your platform configuration. Download the template and fill in your values: curl -o iblai.env https://raw.githubusercontent.com/iblai/vibe/refs/heads/main/iblai.env"

Step 2: Mount AgentTasksTab

// app/(app)/agents/[mentorId]/tasks/page.tsx
"use client";

import { AgentTasksTab } from "@iblai/iblai-js/web-containers/next";

export default function AgentTasksPage() {
  return (
    <div className="flex h-full flex-col bg-white">
      <AgentTasksTab />
    </div>
  );
}

The tab reads tenantKey, mentorId, and username from AgentSettingsProvider and does its own fetching and saving. No props are required.

The tab measures its wrapper to decide how many rows fit, so give it a set height (here h-full inside a full-height layout, as in /iblai-vibe-agent §1). On phones the tab's explanation moves behind an info button in your header when the header has an empty <div data-activity-info-slot />; without one it stays above the tab.

Custom pagination (optional)

The task list and the logs panel use the SDK's IblPagination. Pass PaginationComponent to use your own; it also receives disableNumberedButtons. Phones always get the SDK's "Page x of y" pager:

import { AgentTasksTab } from "@iblai/iblai-js/web-containers/next";

<AgentTasksTab
  PaginationComponent={({ currentPage, totalPages, onPageChange, disabled }) => (
    <nav className="flex gap-2">
      <button disabled={disabled || currentPage <= 1} onClick={() => onPageChange(currentPage - 1)}>
        Previous
      </button>
      <span>
        {currentPage} / {totalPages}
      </span>
      <button
        disabled={disabled || currentPage >= totalPages}
        onClick={() => onPageChange(currentPage + 1)}
      >
        Next
      </button>
    </nav>
  )}
/>;

Step 3: Customize Labels (Optional)

The tab renders with the default agent-facing copy (AGENT_TASKS_TAB_LABELS, localized through the SDK's i18n). Pass a partial labels object to change any string:

import { AgentTasksTab } from "@iblai/iblai-js/web-containers/next";

<AgentTasksTab
  labels={{
    header: { title: "Scheduled tasks" },
    toolbar: { scheduleTask: "New task" },
  }}
/>;

Label groups (TasksTabLabels): header (title, description, info text), toolbar (search, date filter, Schedule Task), metrics (the three counters), list (repeat wording, status words, deleteTask), logs (the logs panel), states (loading and empty states), scheduleDialog (fields, repeat options, startTimeInPast, buttons), deleteDialog (title, confirmation text, buttons), logDetails (field names), and toasts (schedule and delete success and error).

Step 4: Use MCP Tools for Customization

get_component_info("AgentTasksTab")
get_component_info("AgentSettingsProvider")

<AgentTasksTab> Props

Import from @iblai/iblai-js/web-containers/next.

PropTypeRequiredDescription
labelsDeepPartial<TasksTabLabels>NoOverride user-visible strings
PaginationComponentComponentType<{ currentPage, totalPages, onPageChange, disabled, disableNumberedButtons? }>NoPagination for the task list and logs. Defaults to the SDK's IblPagination

Related Exports

From @iblai/iblai-js/web-containers/next:

  • AGENT_TASKS_TAB_LABELS -- the default label bundle.
  • TaskListItem -- a task as listed (id, name, time, repeat, oneOff, enabled, status, rawData).
  • TaskLog -- a run as listed (id, entry, timestamp, periodicAgentId, status, startTime, endTime).
  • TaskDisplayStatus -- Disabled | Running | Failed | Completed | Scheduled.
  • AgentTasksTabProps, TasksTabLabels -- types.

How it saves

Paths are under /api/ai-mentor/orgs/{org}/users/{username}/.

ActionRequest
LoadGET periodic-agents/?mentor_id=<uuid> (plus search; the date filter narrows the fetched page in the browser -- the endpoint has no date filter and ignores the start_date / end_date the tab sends), and GET periodic-agent-logs/?ordering=-created_at for the status icons
Click a taskGET periodic-agent-logs/?periodic_agent={id}
Schedule TaskPOST periodic-agents/ with mentor, title, prompt and task: { name, crontab, enabled: true, one_off, start_time }
Delete TaskDELETE periodic-agents/{id}/

The crontab uses the chosen time. Weekly adds the weekday, Monthly adds the day of the month, and Don't repeat pins the day and month and sets one_off, so the task runs once and then switches itself off.

Platform data

HookPurpose
useGetPeriodicAgentsQueryThe agent's tasks
useGetPeriodicAgentLogsListQueryRun logs (recent, and per task)
useCreatePeriodicAgentMutationSchedule a task
useDeletePeriodicAgentMutationDelete a task

All from @iblai/iblai-js/data-layer. There is no iblai-api-* REST twin for tasks yet; the endpoints above are in the live schema.

Step 5: Verify

Run /iblai-vibe-ops-test before telling the user the work is ready, and give every page, control and state this skill added its own checkpoint — one Playwright test titled <ID> · … in e2e/journeys/, listed in e2e/coverage.json; pnpm e2e:coverage must pass:

  1. pnpm build -- must pass with zero errors.
  2. pnpm test -- vitest must pass.
  3. Touch test /agents/<uuid>/tasks in the browser as /iblai-vibe-ops-test says, signed in as an org admin: the counters and task list render; schedule a one-off task a few minutes ahead; after it runs, click it -- its run appears under Task Logs; read the console; check the phone width.

Important Notes

  • The repeat time carries no timezone: the dialog sends the crontab's hour and minute from the user's clock (the crontab has no timezone field) and start_time in UTC, so a repeat can fire at that hour UTC.
  • "Notify me by email" is not saved: the dialog shows the switch, but the SDK does not send it to the API.
  • Runs are real agent turns: each run sends the prompt to the agent and costs model calls.
  • Shared provider: mount AgentSettingsProvider once at the layout level (/iblai-vibe-agent §1); do not wrap each tab.
  • Peer deps: sonner and @iblai/iblai-web-mentor (pnpm add sonner @iblai/iblai-web-mentor).
  • Brand guidelines: BRAND.md

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.