# Send Keras to your agent
Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.
## Fast path
- Download the package from Yavira.
- Extract it into a folder your agent can access.
- Paste one of the prompts below and point your agent at the extracted folder.
## Suggested prompts
### New install

```text
I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.
```
### Upgrade existing

```text
I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.
```
## Machine-readable fields
```json
{
  "schemaVersion": "1.0",
  "item": {
    "slug": "keras",
    "name": "Keras",
    "source": "tencent",
    "type": "skill",
    "category": "AI 智能",
    "sourceUrl": "https://clawhub.ai/ivangdavila/keras",
    "canonicalUrl": "https://clawhub.ai/ivangdavila/keras",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadUrl": "/downloads/keras",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=keras",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "packageFormat": "ZIP package",
    "primaryDoc": "SKILL.md",
    "includedAssets": [
      "SKILL.md",
      "architectures.md",
      "layers.md",
      "memory-template.md",
      "setup.md",
      "training.md"
    ],
    "downloadMode": "redirect",
    "sourceHealth": {
      "source": "tencent",
      "slug": "keras",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-02T02:18:54.878Z",
      "expiresAt": "2026-05-09T02:18:54.878Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=keras",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=keras",
        "contentDisposition": "attachment; filename=\"keras-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "keras"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/keras"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    }
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/keras",
    "downloadUrl": "https://openagent3.xyz/downloads/keras",
    "agentUrl": "https://openagent3.xyz/skills/keras/agent",
    "manifestUrl": "https://openagent3.xyz/skills/keras/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/keras/agent.md"
  }
}
```
## Documentation

### Setup

On first use, check setup.md for integration guidelines. The skill stores preferences in ~/keras/ when the user confirms.

### When to Use

User builds neural networks with Keras or TensorFlow. Agent handles model architecture, layer configuration, training loops, callbacks, debugging loss issues, and deployment preparation.

### Architecture

Memory lives in ~/keras/. See memory-template.md for setup.

~/keras/
├── memory.md          # Preferred architectures, hyperparams
└── models/            # Saved model configs (optional)

### Quick Reference

TopicFileSetup processsetup.mdMemory templatememory-template.mdLayer patternslayers.mdTraining diagnosticstraining.mdCommon architecturesarchitectures.md

### 1. Sequential vs Functional API

Sequential: simple stacks, no branching
Functional: multi-input/output, skip connections, shared layers
Subclassing: custom forward pass, dynamic architectures

# Sequential - simple stack
model = keras.Sequential([
    layers.Dense(64, activation='relu'),
    layers.Dense(10, activation='softmax')
])

# Functional - flexible graphs
inputs = keras.Input(shape=(784,))
x = layers.Dense(64, activation='relu')(inputs)
outputs = layers.Dense(10, activation='softmax')(x)
model = keras.Model(inputs, outputs)

### 2. Input Shape Patterns

First layer needs input_shape (exclude batch)
Images: (height, width, channels) for channels_last
Sequences: (timesteps, features)
Tabular: (features,)

# Image input
layers.Conv2D(32, 3, input_shape=(224, 224, 3))

# Sequence input
layers.LSTM(64, input_shape=(100, 50))  # 100 timesteps, 50 features

# Tabular input
layers.Dense(64, input_shape=(20,))  # 20 features

### 3. Activation Functions

TaskOutput ActivationLossBinary classificationsigmoidbinary_crossentropyMulti-classsoftmaxcategorical_crossentropyMulti-labelsigmoidbinary_crossentropyRegressionlinear (none)mse or mae

### 4. Regularization Stack

Apply in this order for overfitting:

Dropout - after dense/conv layers (0.2-0.5)
BatchNorm - before or after activation
L2 regularization - in layer (0.01-0.001)
Early stopping - callback with patience

layers.Dense(64, activation='relu', kernel_regularizer=keras.regularizers.l2(0.01))
layers.Dropout(0.3)
layers.BatchNormalization()

### 5. Callbacks Essentials

callbacks = [
    keras.callbacks.EarlyStopping(
        monitor='val_loss', patience=5, restore_best_weights=True
    ),
    keras.callbacks.ModelCheckpoint(
        'best_model.keras', save_best_only=True
    ),
    keras.callbacks.ReduceLROnPlateau(
        monitor='val_loss', factor=0.5, patience=3
    ),
    keras.callbacks.TensorBoard(log_dir='./logs')
]

### 6. Data Pipeline

# tf.data for performance
dataset = tf.data.Dataset.from_tensor_slices((x, y))
dataset = dataset.shuffle(10000).batch(32).prefetch(tf.data.AUTOTUNE)

# ImageDataGenerator for augmentation
datagen = keras.preprocessing.image.ImageDataGenerator(
    rotation_range=20,
    horizontal_flip=True,
    validation_split=0.2
)

### 7. Compile Checklist

model.compile(
    optimizer=keras.optimizers.Adam(learning_rate=0.001),
    loss='categorical_crossentropy',
    metrics=['accuracy']
)

Learning rate: start 0.001, reduce on plateau
Batch size: 32-128 typical, larger = smoother gradients

### Common Traps

Input shape mismatch → check data shape vs model input_shape, exclude batch dim
Loss is NaN → reduce learning rate, check for inf/nan in data, add gradient clipping
Validation loss diverges → add regularization, reduce model capacity, more data
Model not learning → check labels are correct, verify loss function matches task
GPU OOM → reduce batch size, use mixed precision, gradient checkpointing
Slow training → use tf.data pipeline with prefetch, enable XLA compilation

### External Endpoints

EndpointData SentPurposeTensorFlow model hubNone (download only)Pretrained weights when using weights='imagenet'

Note: Transfer learning examples download pretrained weights on first use. Use weights=None for fully offline operation.

### Security & Privacy

Data that stays local:

Model architectures and configs in ~/keras/
Training preferences and hyperparameters

This skill does NOT:

Upload models or data anywhere
Access files outside ~/keras/ and working directory
Store training data

### Related Skills

Install with clawhub install <slug> if user confirms:

tensorflow — TensorFlow operations and deployment
pytorch — Alternative deep learning framework
ai — General AI and ML patterns
models — Model architecture design

### Feedback

If useful: clawhub star keras
Stay updated: clawhub sync
## Trust
- Source: tencent
- Verification: Indexed source record
- Publisher: ivangdavila
- Version: 1.0.0
## Source health
- Status: healthy
- Item download looks usable.
- Yavira can redirect you to the upstream package for this item.
- Health scope: item
- Reason: direct_download_ok
- Checked at: 2026-05-02T02:18:54.878Z
- Expires at: 2026-05-09T02:18:54.878Z
- Recommended action: Download for OpenClaw
## Links
- [Detail page](https://openagent3.xyz/skills/keras)
- [Send to Agent page](https://openagent3.xyz/skills/keras/agent)
- [JSON manifest](https://openagent3.xyz/skills/keras/agent.json)
- [Markdown brief](https://openagent3.xyz/skills/keras/agent.md)
- [Download page](https://openagent3.xyz/downloads/keras)