Let General Chat search the web, and only General Chat
Search is the one capability that fits the profile holding none: every other capability either reads this installation or changes it, and chat's whole contract is that it can do neither. The assistant deliberately does not get it — its contract is that answers come from this install's own documents, and a web result there is an answer that looks sourced and is not. A chat question about this machine hands off to the assistant before the search would run, so it never reaches the internet even with the box ticked. Off by default, and not because it is dangerous: searching sends the operator's question outside the house, which is theirs to decide. Asked for per turn as well as enabled in conf. Provider-agnostic, as asked — searxng, brave, tavily. Only whichever is configured here can be verified; all three read every field by name, so a shape that changes underneath yields no results rather than wrong ones. The explain fixtures asserted chat holds no capabilities at all, which is exactly the guarantee worth keeping. caps=only: now states the set rather than its emptiness, so the check still fails the day something else is granted there.
This commit is contained in:
@@ -84,7 +84,13 @@ const VV_AI_PROFILES_DEF = [
|
||||
'hint' => 'Ordinary conversation. Hands anything about this install to the assistant on its own.',
|
||||
'turns' => 8,
|
||||
'ui' => true,
|
||||
'caps' => [],
|
||||
// The only capability general chat holds, and it holds it *because* chat cannot write.
|
||||
// Search is a read that leaves the house; every other capability in this table either
|
||||
// reads this installation or changes it, and neither belongs on the profile whose
|
||||
// contract is that it has no reach into the machine at all. The Varaverk assistant is
|
||||
// deliberately not given it: its contract is that answers come from this installation's
|
||||
// own documents, and a web result there is an answer that looks sourced and is not.
|
||||
'caps' => ['web_search'],
|
||||
],
|
||||
'code' => [
|
||||
'label' => 'Code Sketcher',
|
||||
@@ -148,6 +154,7 @@ const VV_AI_CAP_MEANING = [
|
||||
'file_findings'=> 'may record, acknowledge and close findings about this installation',
|
||||
'phrasebook' => 'what the operator calls things, and what they have corrected before',
|
||||
'past_fixes' => 'findings already closed — what fixed this last time',
|
||||
'web_search' => 'may search the web — the one capability that sends text off this machine',
|
||||
];
|
||||
|
||||
function vv_ai_profiles(): array { return VV_AI_PROFILES_DEF; }
|
||||
@@ -204,6 +211,10 @@ function vv_ai_profiles_client(): array {
|
||||
'turns' => $p['turns'],
|
||||
'ui' => (bool)$p['ui'],
|
||||
'kind' => in_array('kind_filter', $p['caps'], true),
|
||||
// Whether to offer the search box, on the same terms as the kind filter: derived from
|
||||
// the capability rather than named per profile, so granting or removing it in the
|
||||
// table above is the only edit either side needs.
|
||||
'web' => in_array('web_search', $p['caps'], true),
|
||||
];
|
||||
}
|
||||
return $out;
|
||||
|
||||
Reference in New Issue
Block a user