I think you can achieve this by %(sexp)
. I suggest you refer to an example in this post.
I think this second part is something you can do with setting the type to entry
(instead of the default plain
) and… probably with a targe that includes olp
. There are many posts about it on this forum ans elsewhere, but I think this might be useful.