Source identity
| Field | Recorded value |
|---|---|
| Source type | GitHub source |
| Original record | Janady13/ai-music-system / plugins/train.js |
| Date | Not specified in source |
| Repository | Janady13/ai-music-system |
| Revision | 9a816470ef81edba7a5d8f3aae62c05eead638a7 |
| Branch | main |
| Path or archive member | plugins/train.js |
| Original SHA-256 | fb9334a6e38946d2e230ff096e70f0f3c6b6b7d90a32edf6e9f93bc673c97ee2 |
| Git blob SHA | d7f940e2b66abd52881474ad821118efe708c4c4 |
| Reading-copy SHA-256 | fb9334a6e38946d2e230ff096e70f0f3c6b6b7d90a32edf6e9f93bc673c97ee2 |
Every recorded occurrence
These 3 records contain identical original source bytes. Their paths and revisions remain part of the archive.
| Original record | Branch or archive | Revision / identifier | Original location |
|---|---|---|---|
| Janady13/ai-music-system / plugins/train.js | main | 9a816470ef81edba7a5d8f3aae62c05eead638a7 | Open original |
| Janady13/ai-music-system / plugins/train.js | codex/create-ai-for-music-generation-ifwcfc | cd5207850253ee238f8a267c043b1e3c070ed81a | Open original |
| Janady13/ai-music-system / plugins/train.js | codex/create-ai-for-music-generation | 017052c0e72c6175378aebb7a7f9dd96e82c3ce2 | Open original |
Recovered source transcript
Download complete source text ↓20 lines · 0.6 KB
module.exports = {
name: "train",
scheduleSeconds: 30,
async produceJobs(queue) {
await queue.add("train", { steps: 200 }, {
attempts: 2,
backoff: { type: "fixed", delay: 2000 },
removeOnComplete: 200,
removeOnFail: 200
});
},
async process(job, log) {
const { trainSteps } = require("../lib/training");
const t0 = Date.now();
const steps = Number(job.data?.steps || 200);
const meta = trainSteps(steps);
log.info({ steps, ms: Date.now() - t0, loss: meta.loss.toFixed(4), step: meta.step }, "train tick");
}
};