Photonic hybrid assembly through flexible waveguides