File size: 9,924 Bytes
768f568
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
# Configuration Guide

Comprehensive guide for configuring OPSIIE 0.3.79 XP to match your preferences and requirements.

## πŸ”§ Configuration Files

### Primary Configuration Files
1. **`.env`** - Environment variables and API keys
2. **`kun.py`** - User profiles and Soul Signatures
3. **`terminal_colors.py`** - Theme configuration (Pastel/Vibrant)



## 🌍 Environment Variables (.env)



### Database Configuration

```env

DB_NAME=mnemonic_computer        # PostgreSQL database name

DB_USER=your_username            # Database username

DB_PASSWORD=your_password        # Database password

DB_HOST=localhost                # Database host

DB_PORT=5432                     # Database port

```



### AI Model APIs

```env

# OpenAI (for Nyx agent)

OPENAI_API_KEY=sk-...

ORG_ID=org-...

NYX_ASSISTANT_ID=asst_...



# Google AI (for G1 Black agent)

GOOGLE_API_KEY=AIza...

G1_VOICE_LIVE=your_g1_agent_id



# Kronos (Greek Internal Auditor)

KRONOS_LIVE=your_kronos_agent_id



# ElevenLabs (Voice synthesis)

ELEVENLABS_API_KEY=...

VOICE_ID=...                     # OPSIIE's voice

NYX_VOICE_ID=...                 # Nyx's voice

G1_VOICE_ID=...                  # G1's voice

```



### Web3 & Blockchain

```env

AGENT_PRIVATE_KEY=0x...          # OPSIIE's Ethereum private key

BASE_RPC_URL=https://...         # Base network RPC

ETHEREUM_RPC_URL=https://...     # Ethereum mainnet RPC

POLYGON_RPC_URL=https://...      # Polygon network RPC

```



### Email Configuration

```env

SENDER_EMAIL=your_email@gmail.com

SENDER_PASSWORD=your_app_password  # Gmail app-specific password

```



### Scientific APIs

```env

NCBI_EMAIL=your_email@example.com  # For DNA analysis features

```



## πŸ‘€ User Profile Configuration (kun.py)



### Access Levels



**R-Grade (Master Access)**
- Full system access
- All experimental features
- Web3 operations (`/0x` commands)
- Advanced AI agents (`/ask`, `/room`)
- Financial intelligence (`/markets`)
- DNA analysis (`/dna`)

**A-Grade (Standard Access)**
- Basic conversation
- File operations (`/read`, `/open`, `/close`)
- Voice features (`/voice`, `/voice1`, `/voice2`)
- Limited AI generation (`/imagine`, `/video`, `/music`)
- Email (`/mail`)

### User Profile Structure
```python

users = {

    'YourName': {

        # Basic Information

        'full_name': 'Your Full Name',

        'call_name': 'Your Preferred Name',

        'arpa_id': 'R001',  # R for Master, A for Standard

        

        # Blockchain

        'public0x': '0x...',  # Your Ethereum wallet address

        

        # Database Connection

        'db_params': {

            'dbname': 'mnemonic_computer',

            'user': 'your_db_username',

            'password': 'your_db_password',

            'host': 'localhost',

            'port': '5432'

        },

        

        # Authentication

        'picture': r'C:\path\to\your\photo.jpg',

        

        # Communication

        'mail': 'your_email@example.com',

        

        # Soul Signature (Personalization)

        'soul_sig': [

            "Prefers direct communication",

            "Values efficiency and precision",

            "Enjoys technical discussions",

            # Add your preferences here

        ],

    }

}

```

### Soul Signature Guidelines

The Soul Signature is the highest-priority personalization system. Include:

**Communication Preferences**
```python

"Prefers direct communication without pleasantries"

"Values detailed technical explanations"

"Likes sarcastic humor and wit"

"Avoids template-like responses"

```

**Interests & Expertise**
```python

"Deep interest in blockchain technology"

"Background in molecular biology"

"Enjoys philosophical discussions"

"Works in quantum computing field"

```

**Interface Preferences**
```python

"Prefers dark mode interfaces"

"Likes minimalist design"

"Values visual data representations"

```

**Interaction Patterns**
```python

"Remembers past conversations and builds on them"

"Appreciates when OPSIIE shows initiative"

"Enjoys creative and artistic pursuits"

```

**Personal Instructions**
```python

"Do not use my middle name"

"My favorite color is Lilac"

"Call me by my nickname in casual conversations"

"I'm working on a project about AI ethics"

```

## 🎨 Theme Configuration

### Available Themes
1. **Pastel** - Soft, muted colors for gentle visual experience
2. **Vibrant** - High-contrast, bold colors for enhanced visibility

### Theme Selection

**At Startup**
- Choose theme during splash screen
- Default is Pastel

**During Conversation**
```bash

/theme                    # Opens theme selector

# Or voice command: "theme"

```

### Custom Theme Colors (terminal_colors.py)



```python

PASTEL = {

    'lilac': (200, 162, 200),

    'pink': (255, 182, 193),

    'green': (152, 251, 152),

    # ... other colors

}



VIBRANT = {

    'lilac': (138, 43, 226),

    'pink': (255, 20, 147),

    'green': (0, 255, 0),

    # ... other colors

}

```



## πŸ”Š Voice Configuration



### Voice Modes

```bash

/voice          # Full voice mode (both speak and listen)

/voice1         # OPSIIE speaks, you type

/voice2         # You speak, OPSIIE types

/voiceoff       # Disable voice mode

```



### ElevenLabs Voice IDs

Configure in `.env`:

```env

VOICE_ID=your_opsiie_voice_id         # OPSIIE's primary voice

NYX_VOICE_ID=your_nyx_voice_id        # Nyx agent's voice
G1_VOICE_ID=your_g1_voice_id          # G1 Black agent's voice

```



### Speech Recognition Settings

- Language: English (default)

- Timeout: 20 seconds of inactivity

- Custom word recognition for commands



## 🧬 DNA Analysis Configuration



### NCBI Email

Required for DNA analysis features:

```env

NCBI_EMAIL=your_email@example.com

```



### Database Access

- UniProt: Protein sequences

- Pfam: Protein families

- PROSITE: Protein patterns

- Rfam: RNA families

- miRBase: microRNA sequences

- GtRNAdb: tRNA sequences



## πŸ’° Web3 Configuration



### Supported Chains

```python

CHAIN_INFO = {
    'Base': {

        'chain_id': 8453,

        'rpc_url': os.getenv('BASE_RPC_URL'),

        'symbol': 'ETH',

        'explorer_url': 'https://basescan.org'

    },

    'Ethereum': {

        'chain_id': 1,

        'rpc_url': os.getenv('ETHEREUM_RPC_URL'),

        'symbol': 'ETH',

        'explorer_url': 'https://etherscan.io'

    },

    'Polygon': {

        'chain_id': 137,

        'rpc_url': os.getenv('POLYGON_RPC_URL'),

        'symbol': 'MATIC',

        'explorer_url': 'https://polygonscan.com'

    }

}

```


### Supported Tokens
```python

TOKENS = {

    'Degen': {

        'Base': '0x4ed4e862860bed51a9570b96d89af5e1b0efefed'

    },

    'USDC': {

        'Base': '0x7F5c764cBc14f9669B88837ca1490cCa17c31607',

        'Ethereum': '0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606EB48',

        'Polygon': '0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174'

    }

}

```

### Gas Strategy
```bash

/0x gas low        # 80% of current gas price

/0x gas medium     # 100% of current gas price (default)

/0x gas high       # 150% of current gas price

```

## πŸ“§ Email Configuration

### Gmail Setup
1. Enable 2-Factor Authentication
2. Generate App-Specific Password
3. Add to `.env`:
```env

SENDER_EMAIL=your_email@gmail.com

SENDER_PASSWORD=your_app_password

```

### Known Contacts
Contacts are automatically mapped from kun.py user profiles:
```python

# Any user with 'mail' field becomes a known contact

'mail': 'contact@example.com'

```

## πŸ“ File Processing Limits

### Web Content Limit
```bash

/weblimit 2000    # Set to 2000 characters (500-5000 range)

```

Default: 1000 characters

### Supported File Types
- PDF (.pdf)
- CSV (.csv)
- DOCX (.docx)
- TXT (.txt)
- XLSX (.xlsx)

## 🎡 AI Generation Settings

### Image Generation (Hugging Face)
Default model: `black-forest-labs/FLUX.1-dev`

Change model:
```bash

/imagine model black-forest-labs/FLUX.1-dev

/imagine model hakurei/waifu-diffusion

```

### Video Generation
Default model: `damo-vilab/text-to-video-ms-1.7b` (ModelScope)

Available models:
- modelscope
- zeroscope
- videogen
- tuneavideo

Change model:
```bash

/video model zeroscope

```

### Music Generation
Model: `facebook/musicgen-small`
- Output: WAV format
- Saved to: `outputs/music/`

## πŸ”„ Configuration Updates

### Runtime Changes
Many settings can be changed during operation:
- Theme: `/theme`
- Web limit: `/weblimit <number>`
- Gas strategy: `/0x gas <level>`
- Image model: `/imagine model <name>`
- Video model: `/video model <name>`

### Persistent Changes
Edit configuration files and restart OPSIIE:
- `.env` for API keys and credentials
- `kun.py` for user profiles
- `web3_handler.py` for blockchain settings

## πŸ” Security Best Practices

1. **Never commit `.env` or `kun.py` to version control**
2. **Use environment variables for all secrets**
3. **Rotate API keys regularly**
4. **Use app-specific passwords for email**
5. **Keep private keys secure and backed up**
6. **Limit R-Grade access to trusted users only**

## πŸ“‹ Configuration Checklist

- [ ] .env file created with all required keys
- [ ] PostgreSQL database created and configured
- [ ] Ollama installed with llama3 model
- [ ] kun.py configured with your profile
- [ ] User photo added for facial recognition
- [ ] ElevenLabs voices configured
- [ ] Web3 wallets configured (if using /0x features)
- [ ] Email credentials configured (if using /mail)
- [ ] NCBI email configured (if using /dna)
- [ ] Theme selected
- [ ] Output directories verified

## πŸš€ Next Steps

After configuration:
1. Follow [First Run Guide](first-run.md)
2. Test basic commands
3. Customize Soul Signature
4. Explore [Basic Commands](../user-guides/basic-commands.md)