AI prompts
base on Comprehensive breeding solver for Palworld # Pal Calc
https://github.com/user-attachments/assets/2ededad9-4f0a-47b1-a460-b553be46bdd4
_v1.12.1 recording_
---
**[Click here to get the latest version.](https://github.com/tylercamp/palcalc/releases/latest)** (Expand "Assets" at the bottom, download `PalCalc.UI.exe`, place in its own folder and run.)
<<< **The Pal Calc wiki can be found [here.](https://github.com/tylercamp/palcalc/wiki)** >>>
---
Pal Calc is a breeding solver for Palworld which uses the data from your save file to automatically find the optimal breeding tree for any desired pal, passive skills, and IVs. It will find _the_ optimal path using your own pals, tell you where to find those pals, and estimate how long each step will take.
No more spreadsheets!
No more fumbling between bases and sorting pals!
Stop manually building breeding trees!
**Spend less time planning your game and more time playing it!**
---
Full list of features
- Can detect and read from your local game save files, based on [palworld-save-tools by cheahjs](https://github.com/cheahjs/palworld-save-tools)
- Supports local Steam saves and Xbox saves
- Xbox saves are synced to your PC by downloading the game through the ['Xbox' app on Windows](https://apps.microsoft.com/detail/9mv0b5hzvk9z) and running the game at least once. Save files are synced when the game is run.
- Built for convenience
- All breeding steps will tell you where you can find an involved Pal
- For pals in viewing cages or bases, hover over the Pal's location for a minimap which highlights the base and shows its coordinates
- Create presets to auto-fill commonly used passives in the solver settings
- Provides time estimates on each step, based on probabilities and mechanics [derived by /u/mgxts in this Reddit post](https://www.reddit.com/r/Palworld/comments/1af9in7/passive_skill_inheritance_mechanics_in_breeding/)
- Gender probabilities
- Probability of directly- and randomly-inserted passives
- For directly-inherited passives, probability of getting the desired passives
- Probability of IV inheritance (if enabled)
- Offers the optimal path
- Determines "path efficiency" based on calculated probabilities, not just the total number of steps
- Handles single-root paths, where you successively breed children with another pal you own (one "starting point")
- Handles multi-root paths, where two children are bred (multiple "starting points")
- _See [here](./PalCalc.Solver/README.md) for an overview of the full solver process._
- Flexible search process
- Allows wild pals
- Set a max number of undesired passives if you're ok with imperfect pals
- Set limits on the number of breeding steps
- Choose which pals you want to include by filtering by guilds and players
- Efficient
- Low memory usage and fast load times
- Relatively fast path-solving process, searches take under a minute
- Distributes path-solving work across all available CPU cores
- Save Inspector
- Lists all pal containers (palbox, viewing cages, etc.)
- Inspect pals to see IVs, passives, and attack skills
- Search for specific pals and/or pals with specific IVs, passives, and attack skills
- Manually add pals in custom containers for use in breeding calculations (does _not_ affect Palworld save data)
- Multiple languages
- Supports all languages in Palworld, pal and passives names imported from game files
- Translations for in-app text [can be added](./PalCalc.UI/Localization/README.md)
# Community Help
Pal Calc currently has some outstanding pieces that need more information to resolve. Some of these need some level of reverse engineering, but some can be figured out through experimentation and statistics. An [issue](https://github.com/tylercamp/palcalc/issues) has been created for each item, where more information can be found.
1. Is there a formula for how long breeding takes? Or is it a constant five minutes? [Issue](https://github.com/tylercamp/palcalc/issues/2)
2. What's the probability of wild pals having exactly N passives? [Issue](https://github.com/tylercamp/palcalc/issues/4)
3. Has the passive skill inheritance calculation changed since /u/mgxts reverse engineered it? Was their reverse engineering accurate? [Issue](https://github.com/tylercamp/palcalc/issues/7)
4. Assuming the passive skill inheritance calculation is correct, is Pal Calc's implementation of those probabilities correct? [Issue](https://github.com/tylercamp/palcalc/issues/8)
5. What's a good way to estimate time needed to capture a wild pal of a certain type? e.g. Chikipi would be much faster to find + catch than Paladius. [Issue](https://github.com/tylercamp/palcalc/issues/10)
# Development
Visual Studio Community 2022 is required. The `.CLI` projects act as test programs which can be ran without involving the whole Pal Calc UI.
## Palworld Database
The list of pals, passives, and stats are stored in a `db.json` file embedded in `PalCalc.Model`. This file is generated by the [`PalCalc.GenDB`](./PalCalc.GenDB/) project. Running this project will update the `db.json` file in `PalCalc.Model` which will be used by the rest of the projects. It also updates the Pal icons and in-game map used by `PalCalc.UI`.
`PalCalc.GenDB` will attempt to read and export data from your local Palworld game files. See the [README](./PalCalc.GenDB/README.md) for more info. It uses [CUE4Parse](https://github.com/FabianFG/CUE4Parse), made and maintained by the same developers of the popular modding tool [FModel](https://fmodel.app/), to perform that export.
The `db.json` file should _not_ be modified manually. It should be modified by re-running the `PalCalc.GenDB` project.
## Save File Support
Save file parsing is in `PalCalc.SaveReader`, which is a partial C# port of [palworld-save-tools](https://github.com/cheahjs/palworld-save-tools). See the project's [README](./PalCalc.SaveReader/) for more information.
## Data and Solver Model
Data collected from Palworld or a save file are represented by types in `PalCalc.Model`. Instances of an owned pal within the game are represented by `PalInstance`.
The solver logic in `PalCalc.Solver` wraps this type with `IPalReference` types, which can represent owned, wild, and bred pals. The `IPalReference` types are returned by `PalCalc.Solver.BreedingSolver`, but you can use `OwnedPalReference` results to fetch underlying owned instances.
The overall solver process is described in the project's [README](./PalCalc.Solver/).
## Pal Calc UI
The general structure of the `PalCalc.UI` project is somewhat messy. The application uses WPF and (weak) MVVM, mainly for convenience. MVVM principals and WPF best-practices were not strictly adhered to. There are various hackfixes since many features were unplanned and added through the path of least resistance. Refactoring is planned and gladly accepted.
Entries in the `Resource` folder are set to the `Resource` build action and embedded in the final program.
The Community Toolkit library is used for the viewmodels, which provides the `ObservableObject`, `ObservableProperty`, and other utilities. These use code generation to automatically implement `private` fields annotated with `[ObservableProperty]` as `public` properties with the appropriate `INotifyPropertyChanged` logic.
`GraphSharp`, a defunct library [preserved after the Codeplex shutdown](https://github.com/NinetailLabs/GraphSharp), does not have any documentation. It was added here by referencing [hollowdrutt's implementation](https://github.com/hollowdrutt/GraphSharpDemo) of a useful overview/walkthrough of its usage [by Sacha Barber](https://sachabarbs.wordpress.com/2010/08/31/pretty-cool-graphs-in-wpf/).
## TODOs
- Notify when a pal involved in a breeding path is no longer available in the source save or has been moved
- Optimize app startup time
- Seems to largely be due to JSON deserialization overhead
## Maybe TODOs
- Option to auto-recalc all target pals when changes are detected
- Allow specifying custom db.json
- Attack skill inheritance + solving
- Implement proper graph diffing for the built in GraphSharp animations
", Assign "at most 3 tags" to the expected json: {"id":"12607","tags":[]} "only from the tags list I provide: [{"id":77,"name":"3d"},{"id":89,"name":"agent"},{"id":17,"name":"ai"},{"id":54,"name":"algorithm"},{"id":24,"name":"api"},{"id":44,"name":"authentication"},{"id":3,"name":"aws"},{"id":27,"name":"backend"},{"id":60,"name":"benchmark"},{"id":72,"name":"best-practices"},{"id":39,"name":"bitcoin"},{"id":37,"name":"blockchain"},{"id":1,"name":"blog"},{"id":45,"name":"bundler"},{"id":58,"name":"cache"},{"id":21,"name":"chat"},{"id":49,"name":"cicd"},{"id":4,"name":"cli"},{"id":64,"name":"cloud-native"},{"id":48,"name":"cms"},{"id":61,"name":"compiler"},{"id":68,"name":"containerization"},{"id":92,"name":"crm"},{"id":34,"name":"data"},{"id":47,"name":"database"},{"id":8,"name":"declarative-gui "},{"id":9,"name":"deploy-tool"},{"id":53,"name":"desktop-app"},{"id":6,"name":"dev-exp-lib"},{"id":59,"name":"dev-tool"},{"id":13,"name":"ecommerce"},{"id":26,"name":"editor"},{"id":66,"name":"emulator"},{"id":62,"name":"filesystem"},{"id":80,"name":"finance"},{"id":15,"name":"firmware"},{"id":73,"name":"for-fun"},{"id":2,"name":"framework"},{"id":11,"name":"frontend"},{"id":22,"name":"game"},{"id":81,"name":"game-engine "},{"id":23,"name":"graphql"},{"id":84,"name":"gui"},{"id":91,"name":"http"},{"id":5,"name":"http-client"},{"id":51,"name":"iac"},{"id":30,"name":"ide"},{"id":78,"name":"iot"},{"id":40,"name":"json"},{"id":83,"name":"julian"},{"id":38,"name":"k8s"},{"id":31,"name":"language"},{"id":10,"name":"learning-resource"},{"id":33,"name":"lib"},{"id":41,"name":"linter"},{"id":28,"name":"lms"},{"id":16,"name":"logging"},{"id":76,"name":"low-code"},{"id":90,"name":"message-queue"},{"id":42,"name":"mobile-app"},{"id":18,"name":"monitoring"},{"id":36,"name":"networking"},{"id":7,"name":"node-version"},{"id":55,"name":"nosql"},{"id":57,"name":"observability"},{"id":46,"name":"orm"},{"id":52,"name":"os"},{"id":14,"name":"parser"},{"id":74,"name":"react"},{"id":82,"name":"real-time"},{"id":56,"name":"robot"},{"id":65,"name":"runtime"},{"id":32,"name":"sdk"},{"id":71,"name":"search"},{"id":63,"name":"secrets"},{"id":25,"name":"security"},{"id":85,"name":"server"},{"id":86,"name":"serverless"},{"id":70,"name":"storage"},{"id":75,"name":"system-design"},{"id":79,"name":"terminal"},{"id":29,"name":"testing"},{"id":12,"name":"ui"},{"id":50,"name":"ux"},{"id":88,"name":"video"},{"id":20,"name":"web-app"},{"id":35,"name":"web-server"},{"id":43,"name":"webassembly"},{"id":69,"name":"workflow"},{"id":87,"name":"yaml"}]" returns me the "expected json"