()
| 4270 | const bestScore = (degree[best] || 0) + Number(bestNode?.score || 0) + bestTypeBoost; |
| 4271 | return score > bestScore ? id : best; |
| 4272 | }, graphId(candidates[0] || nodes[0])); |
| 4273 | } |
| 4274 | |
| 4275 | function wikiStatsText(stats, suffix = "") { |
| 4276 | const byType = stats.nodes_by_type || {}; |
| 4277 | const typeParts = [ |
| 4278 | byType.paper ? `${ui().wiki.typePart.paper} ${byType.paper}` : "", |
| 4279 | byType.topic ? `${ui().wiki.typePart.topic} ${byType.topic}` : "", |
| 4280 | byType.section ? `${ui().wiki.typePart.section} ${byType.section}` : "", |
| 4281 | byType.trajectory ? `${ui().wiki.typePart.trajectory} ${byType.trajectory}` : "" |
| 4282 | ].filter(Boolean).join(" · "); |
no test coverage detected