{"id":20942586,"url":"https://github.com/code-monad/appraisal","last_synced_at":"2025-06-19T09:39:31.010Z","repository":{"id":263318177,"uuid":"890012571","full_name":"code-monad/appraisal","owner":"code-monad","description":"Be with Thresh, extended the inputs detail of CKB's transaction info.","archived":false,"fork":false,"pushed_at":"2025-06-15T21:36:24.000Z","size":86,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-15T23:13:39.416Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/code-monad.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-11-17T19:45:15.000Z","updated_at":"2025-06-15T21:36:27.000Z","dependencies_parsed_at":"2024-11-17T20:46:19.832Z","dependency_job_id":"6cd5967d-5086-49a9-ac46-bc8660ab4c80","html_url":"https://github.com/code-monad/appraisal","commit_stats":null,"previous_names":["code-monad/appraisal"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/code-monad/appraisal","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/code-monad%2Fappraisal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/code-monad%2Fappraisal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/code-monad%2Fappraisal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/code-monad%2Fappraisal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/code-monad","download_url":"https://codeload.github.com/code-monad/appraisal/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/code-monad%2Fappraisal/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260726198,"owners_count":23053097,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-18T23:28:23.054Z","updated_at":"2025-06-19T09:39:25.992Z","avatar_url":"https://github.com/code-monad.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Appraisal - Be with Thresh, extended the inputs detail of CKB's transaction info\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n![Rust Version](https://img.shields.io/badge/rust-1.73+-blue.svg)\n\nA high-performance service that enriches CKB transaction data by recursively resolving input details through WebSocket RPC calls. Built with async Rust, it implements a non-blocking architecture to handle concurrent transaction processing efficiently.\n\n## Features\n\n- **Asynchronous Processing**: Leverages Tokio runtime for non-blocking I/O operations\n- **Batch Processing**: Optimizes RPC calls by batching transaction queries\n- **Concurrent Handling**: Configurable concurrency limits for optimal performance\n- **Real-time Communication**: WebSocket for CKB node interaction and MQTT for pub/sub messaging\n- **Robust Error Handling**: Comprehensive error propagation and logging\n- **Docker Support**: Containerized deployment with configurable environments\n\n## Architecture\n\n```mermaid\ngraph LR\n    A[MQTT Source] --\u003e B[Appraisal Service]\n    B \u003c--\u003e C[CKB Node WebSocket]\n    B --\u003e D[MQTT Sink]\n    E[Thresh] --\u003e A\n    C --\u003e E\n```\n\nThe service subscribes to raw transaction events, enriches them with input details by querying the CKB node, and publishes the enhanced transactions to a designated MQTT topic.\n\n## Prerequisites\n\n- Rust 1.73 or higher\n- Docker and Docker Compose (optional)\n- Running CKB node with WebSocket RPC enabled\n- MQTT broker (e.g., Mosquitto)\n\n## Installation\n\n### From Source\n\n```bash\n# Clone the repository\ngit clone https://github.com/yourusername/appraisal.git\ncd appraisal\n\n# Build the project\ncargo build --release\n\n# Run the service\ncargo run --release\n```\n\n### Using Docker\n\n```bash\n# Build the image\ndocker-compose build\n\n# Start the service\ndocker-compose up -d\n```\n\n## Configuration\n\nConfiguration is managed through environment variables:\n\n| Variable | Description | Default |\n|----------|-------------|---------|\n| `RUST_LOG` | Logging level | `info` |\n| `CKB_WS_URL` | CKB node WebSocket URL | `ws://localhost:8114` |\n| `MQTT_HOST` | MQTT broker host | `localhost` |\n| `MQTT_PORT` | MQTT broker port | `1883` |\n| `MQTT_CLIENT_ID` | MQTT client identifier | `ckb-tx-detail-service` |\n| `CONCURRENT_REQUESTS` | Maximum concurrent RPC requests | `10` |\n\n## Usage\n\nThe service subscribes to `ckb.transactions.proposed` MQTT topic and publishes enriched transactions to `ckb.transactions.proposed.detailed`.\n\nExample enriched transaction:\n\n```json\n{\n  \"hash\": \"0x...\",\n  \"inputs\": [\n    {\n      \"previous_output\": {\n        \"index\": \"0x0\",\n        \"tx_hash\": \"0x...\"\n      },\n      \"since\": \"0x0\",\n      \"capacity\": \"0x34e62ce00\",\n      \"lock\": {\n        \"args\": \"0x...\",\n        \"code_hash\": \"0x...\",\n        \"hash_type\": \"type\"\n      },\n      \"type_script\": null\n    }\n  ],\n  // ... other transaction fields\n}\n```\n\n## Development\n\n### Running Tests\n\n```bash\n# Run all tests\ncargo test\n\n# Run tests with logging\nRUST_LOG=debug cargo test -- --nocapture\n```\n\n### Benchmarking\n\n```bash\ncargo bench\n```\n\n## Contributing\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes (`git commit -am 'Add some amazing feature'`)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\n## Performance Considerations\n\n- The service implements connection pooling for WebSocket connections\n- Batch processing reduces RPC overhead\n- Configurable concurrency limits prevent resource exhaustion\n- Error backoff strategies for resilient operation\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Acknowledgments\n\n- [CKB Documentation](https://github.com/nervosnetwork/ckb)\n- [MQTT](https://mqtt.org/)\n\n## Related Projects\n- [Thresh](https://github.com/nervape/thresh)\n- [CKB](https://github.com/nervosnetwork/ckb)\n- [CKB SDK](https://github.com/nervosnetwork/ckb-sdk-rust)\n\n---\n\nFor more information or support, please open an issue or contact the maintainers.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcode-monad%2Fappraisal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcode-monad%2Fappraisal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcode-monad%2Fappraisal/lists"}