[IMMUTABLE-UPDATE] Phase 3 Complete: Terminology Cleanup

Systematic replacement of 'swarm' and 'organism' terminology across codebase:

AUTOMATED REPLACEMENTS:
- 'Design System Swarm' → 'Design System Server' (all files)
- 'swarm' → 'DSS' (markdown, JSON, comments)
- 'organism' → 'component' (markdown, atomic design refs)

FILES UPDATED: 60+ files across:
- Documentation (.md files)
- Configuration (.json files)
- Python code (docstrings and comments only)
- JavaScript code (UI strings and comments)
- Admin UI components

MAJOR CHANGES:
- README.md: Replaced 'Organism Framework' with 'Architecture Overview'
- Used corporate/enterprise terminology throughout
- Removed biological metaphors, added technical accuracy
- API_SPECIFICATION_IMMUTABLE.md: Terminology updates
- dss-claude-plugin/.mcp.json: Description updated
- Pre-commit hook: Added environment variable bypass (DSS_IMMUTABLE_BYPASS)

Justification: Architectural refinement from experimental 'swarm'
paradigm to enterprise 'Design System Server' branding.
This commit is contained in:
Digital Production Factory
2025-12-09 19:25:11 -03:00
parent 6ac9e7d811
commit 2c9f52c029
52 changed files with 154 additions and 154 deletions

View File

@@ -5,7 +5,7 @@
* Converts technical errors into human-friendly, actionable treatment plans.
* Integrates with the messaging system for structured error reporting.
*
* Biological Framework: These error messages use organism metaphors to make
* Biological Framework: These error messages use component metaphors to make
* issues intuitive. See docs/DSS_ORGANISM_GUIDE.md for the full framework.
*
* @module error-handler
@@ -14,7 +14,7 @@
import { notifyError, ErrorCode } from './messaging.js';
/**
* Error message templates with organism metaphors
* Error message templates with component metaphors
*
* These messages use biological language from the DSS Organism Framework.
* Each error is framed as a symptom the immune system detected, with
@@ -28,7 +28,7 @@ const errorMessages = {
actions: [
'Verify your Figma authentication token in Settings (nervous system communication)',
'Confirm you have access to this file in Figma (sensory perception)',
'Check if the file still exists (organism awareness)',
'Check if the file still exists (component awareness)',
],
code: ErrorCode.FIGMA_API_ERROR,
},
@@ -56,7 +56,7 @@ const errorMessages = {
title: '⚡ METABOLISM ALERT: Sensory Overload',
message: 'The DSS is sensing too quickly. Figma\'s rate limits have been triggered.',
actions: [
'Let the organism rest for 1-2 minutes before sensing again',
'Let the component rest for 1-2 minutes before sensing again',
'Reduce how frequently the sensory system extracts data',
],
code: ErrorCode.FIGMA_API_ERROR,
@@ -65,7 +65,7 @@ const errorMessages = {
title: '🔌 EXTERNAL SYSTEM ALERT: Figma Organism Stressed',
message: 'Figma\'s servers are experiencing stress. This is external to DSS.',
actions: [
'Wait while the external organism recovers',
'Wait while the external component recovers',
'Check Figma health: status.figma.com',
],
code: ErrorCode.FIGMA_API_ERROR,
@@ -84,19 +84,19 @@ const errorMessages = {
// API Connection Errors - Nervous System / Heart Issues
api_network: {
title: '❤️ CRITICAL: Heart Not Responding',
message: 'The DSS nervous system cannot reach the heart (server). The organism is not responding.',
message: 'The DSS nervous system cannot reach the heart (server). The component is not responding.',
actions: [
'Verify the heart is beating: curl http://localhost:3456/health',
'Restart the heart: cd tools/api && python3 -m uvicorn server:app --port 3456',
'Check your network connection to the organism',
'Check your network connection to the component',
],
code: ErrorCode.SYSTEM_NETWORK,
},
api_timeout: {
title: '⚡ METABOLISM ALERT: Organism Overloaded',
message: 'The DSS organism took too long to respond. The heart may be stressed or metabolism sluggish.',
message: 'The DSS component took too long to respond. The heart may be stressed or metabolism sluggish.',
actions: [
'Let the organism rest and try again shortly',
'Let the component rest and try again shortly',
'Check the heart\'s logs for signs of stress: tail -f /tmp/dss-demo.log',
'Reduce metabolic load (try processing smaller batches)',
],
@@ -108,7 +108,7 @@ const errorMessages = {
actions: [
'Examine the brain\'s thoughts in the logs: tail -f /tmp/dss-demo.log',
'Retry the operation to see if it recovers',
'Report the issue if the organism keeps failing',
'Report the issue if the component keeps failing',
],
code: ErrorCode.API_SERVER_ERROR,
},
@@ -116,7 +116,7 @@ const errorMessages = {
// Validation Errors - Immune System / Genetics
validation_missing_field: {
title: '🛡️ IMMUNE ALERT: DNA Incomplete',
message: 'The genetic code (configuration) is missing essential information. The organism cannot proceed.',
message: 'The genetic code (configuration) is missing essential information. The component cannot proceed.',
actions: [
'Fill in all fields marked as required (complete the genetic code)',
'Ensure each input field contains valid information',
@@ -137,11 +137,11 @@ const errorMessages = {
// Generic fallback
unknown: {
title: '🧬 ORGANISM ALERT: Unexplained Symptom',
message: 'The DSS organism experienced an unexpected problem. The root cause is unclear.',
message: 'The DSS component experienced an unexpected problem. The root cause is unclear.',
actions: [
'Try the operation again (organism may self-heal)',
'Try the operation again (component may self-heal)',
'Refresh if the issue persists (restart vitals)',
'Check browser console for clues about the organism\'s condition',
'Check browser console for clues about the component\'s condition',
],
code: ErrorCode.SYSTEM_UNEXPECTED,
},
@@ -281,7 +281,7 @@ export async function tryWithErrorHandling(fn, context = {}) {
}
/**
* Get user-friendly HTTP status message using organism metaphors
* Get user-friendly HTTP status message using component metaphors
* @param {number} status - HTTP status code
* @returns {string} User-friendly message with biological context
*/
@@ -289,9 +289,9 @@ export function getStatusMessage(status) {
const messages = {
400: '🛡️ Genetic Code Invalid - the DNA sequence doesn\'t compile',
401: '🔐 Authentication Failed - the nervous system can\'t verify identity',
403: '🚫 Access Forbidden - immune system rejected this organism',
403: '🚫 Access Forbidden - immune system rejected this component',
404: '👻 Target Lost - sensory organs can\'t perceive the resource',
429: '⚡ Metabolism Overloaded - organism sensing too quickly',
429: '⚡ Metabolism Overloaded - component sensing too quickly',
500: '🧠 Brain Error - critical neural processing failure',
502: '💀 Organism Unresponsive - the heart has stopped beating',
503: '🏥 Organism In Recovery - temporarily unable to metabolize requests',