| author | flint | |||||
|---|---|---|---|---|---|---|
| date | 2026-03-24 | |||||
| tags |
|
|||||
| status | active |
A guide for setting up a persistent AI assistant personality with long-term memory using Claude Code and AutoMem.
Install and configure AutoMem - a long-term memory system for Claude Code that persists across sessions.
AutoMem gives Claude Code persistent memory using:
Help me create a custom soul and identity for Claude in this workspace.
https://github.com/openclaw/openclaw/tree/main/docs/reference/templates/SOUL.mdhttps://github.com/openclaw/openclaw/tree/main/docs/reference/templates/IDENTITY.mdhttps://github.com/openclaw/openclaw/tree/main/docs/reference/templates/BOOTSTRAP.md| <?php | |
| /** | |
| * Add a continue reading link on archive pages. | |
| * The link is not shown on the single post view. | |
| * If the user doesn't have access to the post, | |
| * the link is NOT shown, since there should already | |
| * be a message RE having to be a member to see. | |
| * | |
| * Hooks on the `memberlite_after_content_post` action. | |
| * |
| # Block direct execution of PHP inside wp-content/plugins or wp-content/themes | |
| # Add these lines above the WP core rules in .htaccess. | |
| RewriteEngine On | |
| RewriteRule ^wp-content/plugins/[^/]+/.*\.php$ - [F,L] | |
| RewriteRule ^wp-content/themes/[^/]+/.*\.php$ - [F,L] |
| <?php | |
| /** | |
| * Encrypt/decrypt some options stored in the wp_options table. | |
| * Note this will only work for options that are stored as strings. | |
| * | |
| * title: Encrypt/Decrypt Some Options | |
| * layout: snippet | |
| * collection: | |
| * category: | |
| * link: |
| <?php | |
| /** | |
| * Just place this file on the webserver and then point your webhook to the location. | |
| * This will save the incoming timestamp and data to a webhook-handler.log file in the same folder. | |
| * Use `tail -f webhook-handler.log` to monitor the log file. | |
| */ | |
| // Set the log file path | |
| $logFile = __DIR__ . '/webhook-handler.log'; | |
| $timestamp = date('Y-m-d H:i:s'); |
| <?php | |
| /** | |
| * We will consider failed login attempts as spam. | |
| * If a user is consider a spammer, block them from logging in. | |
| * | |
| * Some ideas if we merge this into PMPro core: | |
| * - Need documentation RE bypassing the login block. | |
| * - Consider adding settings RE what spammers are blocked from. | |
| * - Consider a way to view/clear the spam activity queue. | |
| * - We know the username they tried to login with, |
| <?php | |
| /** | |
| * Increase memory and execution time for WP admins and crons | |
| * Add this code into a custom plugin or code snippet. | |
| */ | |
| function my_init_memory() { | |
| if( current_user_can( 'manage_options' ) ) { | |
| ini_set( 'max_execution_time', 300 ); //300 seconds = 5 minutes | |
| ini_set( 'memory_limit', '812M' ); | |
| } elseif ( wp_doing_cron() ) { |
| <?php | |
| /** | |
| * Exclude some extra dirs from the WordPress plugin check plugin. | |
| */ | |
| function my_wp_plugin_check_ignore_directories( $dirs ) { | |
| // For reference, the default dirs as of v1.0.1 | |
| // $default_ignore_directories = array( | |
| // '.git', | |
| // 'vendor', | |
| // 'node_modules', |