It's a well-known fact that there are computable diagonalization functions on Baire space $\mathbb{B} = \mathbb{N}^\mathbb{N}$ (i.e., functions which take a sequence $(r_i)_{i\in \mathbb{N}}$ of elements of $\mathbb{B}$ and produces an element $\mathbb{B}$ not equal to any of the $r_i$'s). I'm curious about whether one such function can generate an 'almost computable enumeration' of the computable elements of $\mathbb{B}$ relative to a path in Kleene's $\mathcal{O}$.

Let's say that a *computable diagonalization function* is a function $h : \mathbb{B}^{\mathbb{N}} \to\mathbb{B}$ with the property that for any sequence $(r_i)_{i \in \mathbb{N}}$ of elements of $\mathbb{B}$, $h((r_i)) \neq r_i$ for every $i \in \mathbb{N}$.

Given any non-zero $e$ in Kleene's $\mathcal{O}$, let $g_e : \mathbb{N} \to \mathcal{O}$ be some enumeration of the set of $<_{\mathcal{O}}$-predecessors of $e$ (possibly with repetitions) chosen so that $g_e(n)$ is uniformly computable in $n$ and $e$.

Given any computable diagonalizing function $h$, by effective transfinite recursion we get a computable function $h^\ast : \mathcal{O} \to \mathbb{B}$ satisfying that $h^\ast(0)$ is some fixed computable name of $(i \mapsto 0) \in \mathbb{B}$ and for any non-zero $e \in \mathcal{O}$, $h^\ast(e) = h(n \mapsto h^\ast(g_e(n)))$.

We then have that for any path $P$ in $\mathcal{O}$ with $c \in P$, $e \mapsto h^\ast(e)$ defines an injection from $P$ into the computable elements of $\mathbb{B}.

Given how flexible paths through $\mathcal{O}$ are, it seems likely to me that with a careful choice of $h$ we can actually get a bijection, but I am unable to come up with an argument.

Question.Does there exist a computable diagonalization function $h$ and a path $P$ in $\mathcal{O}$ such that $h^\ast$ is a bijection between $P$ and the computable elements of $\mathbb{B}?

If no such $h$ and $P$ exist, is it possible if we only require that $h$ be defined on the computable elements of $\mathbb{B}^\mathbb{N}$ (which is all we need for effective transfinite recursion)?

3more comments