Suppose for each of $p$ symptoms we have a measurement of the degree of severity from $1$ to $5$. We have a dataset $\{(x_i,y_i)\}_{i=1}^n$, where $x_i=(x_{ij},j=1,\cdots,p)$ are the measured severities of the symptoms of patient $i$, and $y_i=0$ or $1$ indicates whether or note patient $i$ has the disease.
Let $\pi$ be the prior of class $Y_i=1$.
Then the joint probability over the class variable $Y_i$ and observation $X_i$ is $$ P(X_i,Y_i)=\pi^{Y_i}(1-\pi)^{1-Y_i}\prod_{k=0}^1\prod_{j=1}^p\prod_{v=1}^5\theta_{kjv}^{I(Y_i=k)I(X_{ij}=v)} $$
where $\theta_{kjv}$ is the probability that $X_{ij}=v$ given $Y_i=k$.
Now I am asked to take a Bayesian approach to derive the posterior distribution of parameters $\theta$ and $\pi$, given the dataset $D=\{(x_i,y_i)\}_{i=1}^n$, under the assumption that the prior of $\pi$ is $\text{Beta}(1,1)$ (i.e. uniform) and the prior of $\{\theta_{kjv}\}_{v=1}^5$ is $\text{Dirichlet(1,1,1,1,1)}$ (i.e. uniform on the simplex $\sum_v\theta_{kjv}=1$).
Also, assume the parameters are independent.
Could anyone show me how to do this?
My try is as follow:
$$ \begin{align*} f(\pi|D)&=\frac{P(D|\pi)f(\pi)}{P(D)}\\ &\propto P(D|\pi)\\ &=\int_{\theta\in\text{simplex}}P(D,\theta|\pi)d\theta\\ &=\int_{\theta\in\text{simplex}}P(D|\pi,\theta)f(\theta)d\theta\\ &=\mathbb{E}_\theta[P(D|\pi,\theta)] \end{align*} $$
It is the most I can do, how can I move on to have a closed form for $f(\pi|D)$? It is requires to write it in $n_k$ and $m_{kjv}$ where $n_k$ is the number of data in class $k$, and $m_{kjv}$ is the number of patients in class $k$ with severity level $v$ for symptom $j$.