Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

998 B
Raw Blame
import { useActions, useValues } from 'kea'

import { agentInstructionsSettingsLogic } from './agentInstructionsSettingsLogic'
import { InstructionsEditor } from './InstructionsEditor'

export function AgentPersonalInstructionsSettings(): JSX.Element {
    const { personalInstructions, personalValue, personalDirty, personalInstructionsLoading } =
        useValues(agentInstructionsSettingsLogic)
    const { setPersonalDraft, submitPersonalDraft } = useActions(agentInstructionsSettingsLogic)

    return (
        <InstructionsEditor
            stored={personalInstructions}
            value={personalValue}
            dirty={personalDirty}
            loading={personalInstructionsLoading}
            placeholder="For example: Keep pull request descriptions short. Ask before adding a dependency."
            onChange={setPersonalDraft}
            onSave={submitPersonalDraft}
            dataAttr="agent-personal-instructions"
            ariaLabel="My instructions"
        />
    )
}